You are not logged in. Please login at to post your questions!


Buggy input in ANKPAREN

During the cook59 competition I kept getting NZEC but I couldn't understand why. I verified my answers for all possible input strings up to length 12, and thousands of random input strings up to max length. Here is my code, it uses the same method as the official solution.

After the competition I found the problem: when I read the input I have to say:

String s =;

instead of

String s = scan.nextLine();

I always use nextLine() in CodeChef competitions, and both cases work on the sample input. This means my answer was correct but failed due to bad input. This is very disappointing. :(

Here is someone else with the same problem.

Would the admins consider rejudging the problem (or just people that failed due to NZEC) with input that matches the sample input?

asked 22 Jun '15, 01:30

luc4sdreyer's gravatar image

accept rate: 10%

edited 24 Jul '15, 16:54

admin's gravatar image

0★admin ♦♦

We are investigating the issue. We will rejudge the problem as soon as we confirm this. We are really sorry for the situation.


answered 22 Jun '15, 09:46

dpraveen's gravatar image

4★dpraveen ♦♦
accept rate: 20%

toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text]( "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported
  • mathemetical formulas in Latex between $ symbol

Question tags:


question asked: 22 Jun '15, 01:30

question was seen: 1,157 times

last updated: 24 Jul '15, 16:54