11286 - Conformity
Moderator: Board moderators
11286 - Conformity
What is the best data structure in this problem to look for duplication? I don't know STL stuff, I only know basic C code... Any suggestion is welcome.
I get WA for this problem, due to the current status of the new server, I don't know whether it is really WA or other errors shown as WA. I 've tried some test cases and got correct answer. I 've tried to implement a trie. Can you people help me? thanks.
[EDIT] I misunderstood the problem, ACC now. I 've implemented trie. thanks all.
[EDIT] I misunderstood the problem, ACC now. I 've implemented trie. thanks all.
asd
hi,i got WA...can anyone give me the testcase please ?
thanks.
thanks.
Try this case
Hope it will works
Thanks
Keep posting
Sapnil
Hope it will works
Code: Select all
Input:
4
100 101 102 103 104
104 103 100 101 102
200 201 202 203 204
204 203 200 201 202
5
100 101 102 103 104
100 101 102 103 104
100 101 102 103 104
100 101 102 103 104
100 101 102 103 104
5
100 101 102 103 104
100 101 102 103 104
100 101 102 103 104
100 101 102 103 104
100 101 102 103 105
Output:
2
0
4
Keep posting
Sapnil
>>sapnil
r u sure that these outputs r correct??
My AC code gives the following output.
r u sure that these outputs r correct??
My AC code gives the following output.
Code: Select all
4
5
4
asd
emm..which is the answer ?
now my code give me :
but still got WA...any testcase again ?
does 0 is an input ?
thanks..
now my code give me :
Code: Select all
4
5
4
does 0 is an input ?
thanks..
To mmonish>>sapnil
r u sure that these outputs r correct??
My AC code gives the following output.Code: Select all
4 5 4
Yes me AC code returns this output!
Thanks
Keep posting
Sapnil
"Dream Is The Key To Success"
@@@ Jony @@@
@@@ Jony @@@
-
- Experienced poster
- Posts: 147
- Joined: Mon Jun 07, 2010 11:43 am
- Location: University Of Dhaka,Bangladesh
- Contact:
Re: 11286 - Conformity
Read the data as strings,sort them,concatanate them placing separators in middle. than use map. simple
UVa stats: http://felix-halim.net/uva/hunting.php?id=63448
My blog on programming: http://www.shafaetsplanet.com/planetcoding/
My blog on programming: http://www.shafaetsplanet.com/planetcoding/
Re: 11286 - Conformity
Here's some input / output I found useful during testing / debugging.
Input:
AC Output:
Input:
Code: Select all
3
100 101 102 103 488
100 200 300 101 102
103 102 101 488 100
3
200 202 204 206 208
123 234 345 456 321
100 200 300 400 444
10
100 200 300 400 444
444 100 200 300 400
100 300 400 444 200
100 200 400 444 300
100 444 200 300 400
111 222 333 444 455
222 333 444 455 111
222 333 455 111 444
455 111 222 333 444
111 222 444 455 333
16
100 200 300 400 444
444 100 200 300 400
100 300 400 444 200
100 200 400 444 300
100 444 200 300 400
111 222 333 444 455
222 333 444 455 111
222 333 455 111 444
455 111 222 333 444
111 222 444 455 333
123 321 222 333 444
444 123 321 222 333
321 123 222 333 444
222 123 321 333 444
333 123 321 222 444
123 444 321 222 333
4
123 222 388 488 188
299 222 388 488 188
466 299 222 388 488
466 299 222 388 450
0
Code: Select all
2
3
10
6
4