← Back to topics
Topic

Quals 2010 #1

_
_qwAker_
In the task SORTSRE of this contest test cases have windows #10#13 new line symbols instead of linux #10 so my C++ solution using 'scanf("%d\n")' didnt read this new line but next 'gets()' read it and all the tests made wrong! I think it not fair, because most of task on z-trening has #10 as new line, mainly because g++ compiler is for linux, and this task hasnt any note about it.

The same problem is in the task PALDRM, changing "putchar('\n')" into "putchar(10);putchar(13);" brings a full score!

Can we hope for a fair assessment of these tasks?
k
karakondzula
I'm having some troubles with 'sortsre'. I see that you have done it so I wont to know how did you read input?
_
_qwAker_
scanf("%s") instead gets() solves problem.
k
karakondzula
Huh, I didn't have input problems I just didn't checked whole strings!
Thanks for help anyway.
_
_qwAker_
Be more attentive next time ;)
b
boba5551
We have been thinking about this post and decided not to change test cases.
As we didn't specify that new line will end with CR+LF, we also didn't specify it will end only CF. We didn't thought in this case it is very important to give additional note/comment, because you can always read string with %s or, to be sure that you have read the whole line, you can use additional gets, as you have mentioned.
We didn't expect for <space> and <tab> to be considered as characters of strings, so simply %s works.

I am sorry if you don't agree with this and if you feel it's not fair, but we believe this decision is fair.

Best regards,
_
_qwAker_
Ok, but i think next time it will be better if there is some feedback to catch problems like that..
b
boba5551
Yes, I agree with you.