Page 4 of 5

Re: 10009 - All Roads Lead Where?

Posted: Sun Dec 30, 2012 7:32 pm
by @ce
@brianfry713....Doesn't help...still RE...
I have submitted most of my questions in C++ without return 0. Its mandatory in C but not in C++, thats not the reason for RE in this case.

Re: 10009 - All Roads Lead Where?

Posted: Tue Jan 01, 2013 2:31 am
by brianfry713
Maybe there are more than 30 cities.

Re: 10009 - All Roads Lead Where?

Posted: Tue Jan 01, 2013 10:12 am
by @ce
@brianfry713, the question states
A city name consists of one or more letters, the first of which is in uppercase. No two cities begin with the same letter.
So, there can be maximum 26 cities.

Re: 10009 - All Roads Lead Where?

Posted: Wed Jan 02, 2013 4:15 am
by brianfry713
line 55 should be
b = m.find(str2)->second;
instead of
a = m.find(str2)->second;

Re: 10009 - All Roads Lead Where?

Posted: Wed Jan 02, 2013 7:40 am
by @ce
Thanks brianfry713...I got AC.

Re: 10009 - All Roads Lead Where?

Posted: Tue Mar 05, 2013 10:01 pm
by Labib
i dunno for what reason my mapped values change..
eg in the test case :
1
6 1
Rome BUET
BUET TSC
TSC Shahbag
Sahbag Nilkhet
Nilkhet Katabon
Katabon ElephantRoad
ElepehantRoad Rome

mapped value of ElepehantRoad should be 7.
but it changes to 0 when queried.

can anyone tell me what I should do?
thnx in advance.

Code: Select all

AC

Re: 10009 - All Roads Lead Where?

Posted: Tue Mar 05, 2013 10:16 pm
by brianfry713
You changed the spelling
ElephantRoad
ElepehantRoad

Re: 10009 - All Roads Lead Where?

Posted: Tue Mar 05, 2013 10:27 pm
by Labib
testcase was from an earlier post... has problems
but the main code still WA :( @brainfry

Re: 10009 - All Roads Lead Where?

Posted: Thu Mar 07, 2013 3:03 am
by brianfry713
That is AC code.

Re: 10009 - All Roads Lead Where?

Posted: Fri Mar 08, 2013 1:33 pm
by Labib
that's rilly weird
but thanks anyway brainfry! :)

Re: 10009 - All Roads Lead Where?

Posted: Wed Jun 26, 2013 10:24 pm
by Loading...
please give me critical test case , that i could find the bug in my code .
Thanks in advance .

Re: 10009 - All Roads Lead Where?

Posted: Thu Jun 27, 2013 12:03 am
by brianfry713
Try the I/O in this thread.

Re: 10009 - All Roads Lead Where?

Posted: Wed Nov 13, 2013 8:52 am
by kimbbakar
problem link: http://ideone.com/y8wRUO

Can anyone give me some test case?

Re: 10009 - All Roads Lead Where?

Posted: Thu Nov 14, 2013 12:30 am
by brianfry713
Don't print a blank line at the start of the output.

Re: 10009 - All Roads Lead Where?

Posted: Fri Nov 15, 2013 11:21 am
by kimbbakar
Thank you so much bro :D