Welcome to the CSC Q&A.
Get help and give help!
Write great code!
It is our choices... that show what we truly are, far more than our abilities.


0 votes
asked in CSC201 by (108 points)

1 Answer

0 votes

Looks like you figured it out from your Moodle score.

In general, when a hidden case fails, the code wasn't written to handle all cases.

Perhaps a loop was always executing a certain number of times instead of dependent on the input.

Maybe the code has conditional statements trying to match all of the specific input data you can see instead of writing a general solution.

Perhaps the hidden code is testing an "edge" case. For example a condition was supposed to be true for num <= 6 and you had num < 6, then my hidden test code checks the = 6 case.

Those are examples that would make a hidden test fail.

answered by (4.2k points)