## Search found 56 matches

Wed Aug 26, 2009 11:09 am
Forum: Volume 100 (10000-10099)
Topic: 10060 - A hole to catch a man
Replies: 22
Views: 6018

### Re: 10060 - A Hole to Catch a Man

Thanks MAK. It's AC after modifications..
Mon Aug 24, 2009 9:37 am
Forum: Volume 100 (10000-10099)
Topic: 10060 - A hole to catch a man
Replies: 22
Views: 6018

### Re: 10060 - A Hole to Catch a Man

I am getting TLE!! #include <cstdio> #include <cmath> using namespace std; int main () { int N, i, nP, res; double thick, x[2000], y[2000], area, sheetVol, manholeVol, mrad, mth; while (scanf("%d", &N) && N) { sheetVol = 0.0; while (N--) { nP = 0; scanf("%lf", &thick); scanf("%lf %lf", &x[nP], &y[nP...
Thu Jan 15, 2009 11:46 am
Forum: Volume 100 (10000-10099)
Topic: 10013 - Super long sums
Replies: 212
Views: 38529

### Re: 10013 - Super Long Sums

Hi this is my code, can anybody tell me why is that i'm getting TLE please :( gets(aux); This is not necessary. Leave it to cin. vector<int> resp; Input range is huge. I got AC with array size of 1000000. So, vector isn't fast enough data structure for this problem. Use static array. if(resp[resp.s...
Thu Jan 15, 2009 10:53 am
Forum: Off topic (General chit-chat)
Topic: New here
Replies: 9
Views: 39915

### Re: New here

Code: Select all

``````If (kajer_shuru<time && time< kajer_shesh) {
cout<<"No waste of time in gossiping.........";
}
else
``````
Hey men, don't doubt on it.
Above program is AC!!
Mon Jan 12, 2009 6:25 pm
Forum: Volume 4 (400-499)
Topic: 445 - Marvelous Mazes
Replies: 93
Views: 9992

### Re: 445 - Marvelous Mazes

Code: Select all

``````if(str[i]=='\0')
break;
if(str[i]>=48 && str[i]<=56)
{
sum=sum+str[i]-48;
continue;
}
``````
What about the digit 9? Why are ignoring it? It's not any less important to get AC. Other parts of the code seems okay.
Wed Jan 07, 2009 4:37 pm
Forum: Volume 4 (400-499)
Topic: 476 - Points in Figures: Rectangles
Replies: 87
Views: 7475

### Re: 476 WA Can anyone tell me why?

You can write like this

Code: Select all

``if(judge==0 && x1!=9999.9)``
For doubles, you should use like this

Code: Select all

``if (fabs(x1-9999.9)<EPS)``
Don't create new threads on same topic.
Wed Jan 07, 2009 1:52 pm
Forum: Bugs and suggestions
Topic: You are not authorised to view this resource.
Replies: 10
Views: 10365

### Re: You are not authorised to view this resource.

Nice tricks. Thanks tryit1.
Wed Jan 07, 2009 1:43 pm
Forum: Volume 1 (100-199)
Topic: 100 - The 3n + 1 problem
Replies: 1394
Views: 178953

### Re: 100 : Wrong Answer

http://online-judge.uva.es/board/viewto ... ?f=1&t=386

Wed Jan 07, 2009 1:37 pm
Forum: Volume 1 (100-199)
Topic: 100 - The 3n + 1 problem
Replies: 1394
Views: 178953

### Re: 100: time exceeded

http://online-judge.uva.es/board/viewto ... ?f=1&t=386

Thu Dec 25, 2008 2:10 am
Forum: Volume 4 (400-499)
Topic: 445 - Marvelous Mazes
Replies: 93
Views: 9992

### Re: 445 - Marvelous Mazes

Try these inputs input: 1T1b5T!1T2b1T1b2T!1T1b1T2b2T!1T3b1T1b1T!3T3b1T!1T3b1T1b1T!5T1*1T! 11X21b1X! 4X1b1X! 3X3b3X1b1X5b1X1b1X2b1X3b1X2b1X1b4X1b4X1b1X3b3X 1b1X4b1X1b1X1b1X2b1X2b1X1b2X1b1X3b2X1b1X1b1X2b1X1b1X2b1X1b3X2b1X 1b1X4b3X2b1X1b1X1b1X2b1X1b2X3b1X1b2X1b1X2b1X1b1X2b1X1b1X1b1X3b1X 3X3b1X5b1X1b1X3...
Thu Dec 25, 2008 1:53 am
Forum: Volume 1 (100-199)
Topic: 102 - Ecological Bin Packing
Replies: 485
Views: 32996

### Re: 102: Wrong answer. Why? Anything i have misunderstand?

jingtra wrote:

Code: Select all

``````    add(bin,result);
int min=10000000;
.......
``````
You can take any of the values of sum as min initially and then continue to find which one is actual min. At least it will solve the problem if your min is not large enough..
Thu Dec 25, 2008 12:57 am
Forum: Volume 1 (100-199)
Topic: 130 - Roman Roulette
Replies: 25
Views: 2213

### Re: problem 130 WA need some sample

Try these inputs:

Code: Select all

``````Input:
1 1
1 5
5 2
7 3
50 9
100 9
100 53
100 5
5 4
11 93
0 0

Output:
1
1
3
1
45
34
13
40
5
2

``````
Your output is different. Hope this helps.
Sat Oct 18, 2008 2:10 pm
Forum: Volume 4 (400-499)
Topic: 478 - Points in Figures: Rectangles, Circles, Triangles
Replies: 44
Views: 10470

### Re: 478 point in triangle ?? getting WA

Newton wrote: i tried but cant find the bug. please help me where is my faults. why this code does not give me write output??? In problem description, The remaining lines will contain the x-y coordinates, one per line, of the points to be tested. The end of this list will be indicated by a point wit...
Thu Oct 09, 2008 12:30 pm
Forum: Volume 4 (400-499)
Topic: 489 - Hangman Judge
Replies: 52
Views: 14038

### Re: confuse 489 with online judge

What is the output for input
1
cheese
ch
Sun Sep 21, 2008 10:19 am
Forum: Volume 3 (300-399)
Topic: 336 - A Node Too Far
Replies: 121
Views: 39134

### Re: 336 input wrong or misunderstanding?

I was getting frequent WA in this problem. I used adjacency lists implemented by arrays. It was handling at most 40 nodes. After watching this topic I increased the array size and got accepted. Vector implementations though don't have this problem. It seems there are more than 40 nodes in testcases ...