0

enter image description here

i have tried a lot but cannot find the meaning of the last two errors of check50 please help

0

The first error probably means that your program generated an error when executed with the particular test data. The second error definitely means that the program was executing too long, and it ran up against the check50 timers and timed out. Usually, this means that there's an infinite loop. Occasionally, it's just because the code is simply too inefficient.

Both errors are coming from tests that verify that a number isn't in the list. The first is for a number that would be larger than the largest number in the list. The second error is in a test where the target would fall somewhere between the endpoints of the list, if it were in the list. This tells me that there's a problem with the search code that it doesn't handle numbers not in the list correctly. You should spend some time figuring out, maybe on paper, what your code actually does as it approaches the end of a search.

If this answers your question, please click on the check mark to accept. Let's keep up on forum maintenance. ;-)

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .