You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Problem 213: Checker output format is inconsistent with the statement and test answers #185
Problem 213 has an output-format mismatch between the problem statement and the checker.
The statement requires each operation to contain three integers:
l r direction
The sample output and the provided answer files use the same three-integer format. However, algorithmic/problems/213/chk.cc reads only two integers for each operation:
x=ouf.readInt(); y=x+m-1; z=ouf.readInt();
As a result, for a statement-compliant operation such as l r direction, the checker interprets r as direction and will normally reject the output as illegal.
Impact
This mismatch makes it impossible for a submission that follows the documented output format to receive any score. The first ordinary three-integer operation is misparsed, the right endpoint is checked as if it were the direction, and the checker terminates with a wrong-answer verdict before validating the constructed sequence or calculating a score.
Because the two-integer format actually expected by the checker is neither documented nor used by the sample and answer files, contestants cannot produce a scoring submission from the repository's published specification.
There are also several related inconsistencies in the problem package:
testdata/1.ans selects x = 3 for an input with n = 2 and provides an operation without a direction value.
The statement says that x and m are printed on the first line, while the sample prints them on separate lines.
The statement specifies a 5-second time limit, but config.yaml specifies 2 seconds.
Suggested changes
Update the checker to read all three operation fields:
x = ouf.readInt();
y = ouf.readInt();
z = ouf.readInt();
Then keep the existing interval-length, bounds, and direction validation.
Replace testdata/1.ans with a valid answer, for example:
Activity
whuang369 commentedon Sep 10, 2026
#188 solves this issue, thanks!
Fix FrontierCS#185: align problem 213 checker with the documented out…