Search found 49 matches

by shihabrc
Wed Jan 18, 2006 5:07 pm
Forum: Volume 108 (10800-10899)
Topic: 10842 - Traffic Flow
Replies: 17
Views: 9826

Thanx a lt. Got AC. I really missed that point. :oops:
by shihabrc
Wed Jan 18, 2006 12:58 am
Forum: Volume 108 (10800-10899)
Topic: 10842 - Traffic Flow
Replies: 17
Views: 9826

10842 Traffic Flow. -----Stuck in traffic jam(WA)

I've used MAXIMUM spanning tree 2 solve. But I'm gettin WA. I've tested several types of Inputs. But cannot find out why WA. Plz Somebody hlp.

Code: Select all

//removed after AC
Plz help(Sugg,I/Os... anything)

-Shihab
by shihabrc
Tue Jan 17, 2006 11:21 pm
Forum: Volume 109 (10900-10999)
Topic: 10977 - Enchanted Forest
Replies: 42
Views: 17748

I've changed my code now & has got rid of RTE. But now I'm getting WA. I just don't get it. Can anyone hlp. I've considered curtesian distance between cells while editing the map 4 jiggypuffs. #include<cstdio> #include<queue> #include<cmath> using namespace std; #define INF 9999999 typedef struct Po...
by shihabrc
Thu Jan 05, 2006 10:18 pm
Forum: Volume 3 (300-399)
Topic: 336 - A Node Too Far
Replies: 121
Views: 40371

Finally I've got AC. I just rewrote the code & this time used STL (set<>) to separate the nodes. All other things r same. My be my process of separating the nodes in the older code was wrong.

Thanks mahmud vai 4 ur I/Os.

-Shihab
by shihabrc
Thu Jan 05, 2006 11:54 am
Forum: Volume 3 (300-399)
Topic: 336 - A Node Too Far
Replies: 121
Views: 40371

Yes, it handles disconnected network. And it also produced correct output 4 ur input. And i've also checked the code 4 any wrong loops(like the one in 388 :oops: ). the standing node is always considered reachable. this code ensures it: if(d[i]>q) n++; 4 the standing node d =0. if(q==0) (q=TTL), the...
by shihabrc
Wed Jan 04, 2006 10:22 pm
Forum: Volume 3 (300-399)
Topic: 388 - Galactic Import
Replies: 7
Views: 2906

Thanx a lot Mahmud vai. I really missed that loop. I've got AC now.And i'll be careful about not revisiting a node in future.

-Thanx.
Shihab
by shihabrc
Wed Jan 04, 2006 6:35 pm
Forum: Volume 3 (300-399)
Topic: 336 - A Node Too Far
Replies: 121
Views: 40371

But I'm still gettin WA. :cry: Can anyone gettin AC give me some I/O.(Though i've tried a lot) Sould i have 2 consider any special cases.

-Shihab [/quote]
by shihabrc
Wed Jan 04, 2006 6:29 pm
Forum: Volume 3 (300-399)
Topic: 388 - Galactic Import
Replies: 7
Views: 2906

mahmud vai, thanks 4 the I/0s. My code has passed these I/Os and also the ones I made. But not getting AC. Here's my code:

Code: Select all

//code removed after getting AC
by shihabrc
Tue Jan 03, 2006 8:26 pm
Forum: Volume 3 (300-399)
Topic: 369 - Combinations
Replies: 101
Views: 17508

U can try long double data type.But __int64/long long is sufficient. Try to evaluate C(n,m) as product of
(n-i)/(i+1) for i=0 to n-1;

-Shihab
by shihabrc
Tue Jan 03, 2006 8:19 pm
Forum: Volume 3 (300-399)
Topic: 388 - Galactic Import
Replies: 7
Views: 2906

388 - Galactic Import

Can someone gettin AC in this prob give me some I/O. I cann't understand Why my code is givin WA.

-Shihab
by shihabrc
Fri Dec 30, 2005 9:09 pm
Forum: Volume 109 (10900-10999)
Topic: 10977 - Enchanted Forest
Replies: 42
Views: 17748

Still getting RTE

Its true that my code is a bit clumsy, sorry 4 that. Inside main() i've mostly worked for taking the input and constructing the forest grid(adMat[][]). And no point is enqued more than once, since the entry colour [j] is maintained to check wheather a point adMat [j] was previously visited or not. S...
by shihabrc
Thu Dec 29, 2005 9:42 pm
Forum: Volume 109 (10900-10999)
Topic: 10977 - Enchanted Forest
Replies: 42
Views: 17748

Still getting RTE

Sorry. I've changed the size of que to 40100, which is large enough to hold 200x200 points.(according to the prob statement the forest will be at most 200x200 grid.) But i'm still getting RTE. Pleaz help me.
by shihabrc
Thu Dec 29, 2005 9:30 pm
Forum: Volume 3 (300-399)
Topic: 336 - A Node Too Far
Replies: 121
Views: 40371

336 A node too far. WA getting mad. Plz someone help

I used BFS to solve this.But its givin WA. I don't know why. I've tried lots of input (including loops,disconnected network). All is correct. But Still having WA. Plz some one help. Should i have 2 consider cases where a node is not in the description but is in the query. Like: 4 0 0 1 2 2 3 3 3 5 1...
by shihabrc
Thu Dec 29, 2005 2:08 pm
Forum: Volume 109 (10900-10999)
Topic: 10977 - Enchanted Forest
Replies: 42
Views: 17748

10977 - Enchanted Forest

I don't know why i'm getting RTE for this prob.(there is no chance of array overrun or negetive indexing,though my memory management is not that efficient) It made me really mad during the contest. Still now i can't find the problem . Plaeaaz somebody help.

Code: Select all

Cut
-Shihab
by shihabrc
Tue Oct 11, 2005 10:16 am
Forum: Volume 4 (400-499)
Topic: 476 - Points in Figures: Rectangles
Replies: 87
Views: 7945

476 RTE!! PLZ HLP

THis code is generating RTE. I can't find why. can anyone hlp. plzz. #include<stdio.h> typedef struct rectangle{ char des[5]; long double tlx,tly,brx,bry; } rect; typedef struct point{ long double x,y; } point; void init(void); void inits(void); void swap(long double *,long double *); rect r[1000]; ...

Go to advanced search