Task 170 wont submit

Back to General discussions forum

Mohamed Aziz     2015-10-29 12:49:28
User avatar

Hello I think my code is all right but the checker tells me You are expected to return 5566 country codes!

This is the testcase http://pastebin.com/TmcX8CJV

This is the output of my pascal program

I outputs 5566 country code because when I run ./binary-search-in-array < testcase.txt | tr -cd " " | wc -c

I get 5566 (I have an extra space in the end)

Is the output of my program Incorrect ? http://pastebin.com/BFX5pNry

I also copy the output using ./binary-search-in-array < testcase.txt | xclip -i -selection clipboard

and the program runs under a minute (about 0.04s) ./binary-search-in-array < testcase.txt > /dev/null 0.04s user 0.04s system 78% cpu 0.101 total

Thanks guys!

Solved my bad

Mohamed Aziz     2015-10-29 12:49:59
User avatar

Oh sorry solved this it's because of the extra space in the end my bad ...

Rodion (admin)     2015-10-29 15:53:55
User avatar

Hi! Thank you for reporting this!

Really it looks like a small bug - I think the checker should be tolerant to extra space. I'll try to see, whether it can be easily fixed!

Please login and solve 5 problems to be able to post at forum