Search found 8 matches

by Aarya
Tue Mar 11, 2014 7:24 pm
Forum: Volume 103 (10300-10399)
Topic: 10354 - Avoiding Your Boss
Replies: 47
Views: 26588

Re: 10354 - Avoiding Your Boss

Thanks Brian Fry. :D
by Aarya
Sun Mar 09, 2014 6:21 pm
Forum: Volume 103 (10300-10399)
Topic: 10354 - Avoiding Your Boss
Replies: 47
Views: 26588

Re: 10354 - Avoiding Your Boss

Your boss must not see you outside your home. You can assume that the cost of reaching another location in the same place is zero and you must go outside your home to reach market and your boss must come outside to reach home (from office) or office (from home) If I understood this statement correc...
by Aarya
Tue Mar 04, 2014 4:03 pm
Forum: Volume 6 (600-699)
Topic: 615 - Is It A Tree?
Replies: 71
Views: 32847

Re: 615 - Is It A Tree?

Input: 1 2 2 3 4 3 2 4 0 0 1 2 2 3 4 5 0 0 1 7346537 37542 1 0 0 7 7 0 0 8 9 0 5 0 0 100 1 1 2 9 7 7 3 3 88 88 6 1 9 2 6 0 0 1 2 1 2 0 0 999999 5 0 0 0 0 -1 -1 Output: Case 1 is not a tree. Case 2 is not a tree. Case 3 is a tree. Case 4 is not a tree. Case 5 is not a tree. Case 6 is not a tree. Case...
by Aarya
Sun Dec 08, 2013 10:36 am
Forum: Volume 127 (12700-12799)
Topic: 12707 - Block Meh
Replies: 1
Views: 983

Re:12707-Block Meh

Continuously getting Wrong Answers: Plz help. Thanks in Advance #include<cstdio> #include<vector> #include<cstring> #include<algorithm> //#include<conio.h> using namespace std; struct type { int x, y; bool operator < (const type& p) const { if(x==p.x) return y > p.y; return x < p.x; } }; vector<...
by Aarya
Tue Dec 03, 2013 7:06 pm
Forum: Volume 112 (11200-11299)
Topic: 11228 - Transportation system.
Replies: 30
Views: 17351

Re: 11228 - Transportation System

Thanks Brian fry for your brilliant test cases.

Now got AC
by Aarya
Thu Nov 28, 2013 8:44 am
Forum: Volume 115 (11500-11599)
Topic: 11504 - Dominos
Replies: 55
Views: 29720

Re: 11504 - Dominos

Brian fry, My code outputs all the cases posted by you perfectly. But still WA. #include<cstdio> #include<queue> #include<vector> #include<cstring> using namespace std; int no_of_connections, no_of_tiles, count_1 = 0; char color[100050]; vector<int>data[100050]; void read_input(void); void search_it...
by Aarya
Fri Nov 22, 2013 8:51 am
Forum: Volume 112 (11200-11299)
Topic: 11228 - Transportation system.
Replies: 30
Views: 17351

Re: 11228 - Transportation System

Thanks Brian fry for replying. I see my bug was in determining the number of states. At first I assumed that "if distance between two cities is greater than r then theys are in different states". But seeing your accepted output I changed it to "if distance is greater than or equal r t...
by Aarya
Thu Nov 21, 2013 6:17 pm
Forum: Volume 112 (11200-11299)
Topic: 11228 - Transportation system.
Replies: 30
Views: 17351

Re: 11228 - Transportation System

Wrong answer every time: It passes all the test cases posted here. I can't find the bug. If you can please tell me. Thanks :( [#include<cstdio> #include<cmath> #include<iostream> #include<vector> #include<stdlib.h> #include<algorithm> #define dist sqrt((x -x[j])*(x -x[j]) + (y -y[j])*(y -y[j])) usin...

Go to advanced search