Ask Question
2 September, 13:30

Jimmy wrote the procedure scoreToGrade which accepts as a parameter score - a quiz score in the range 0-100. The procedure is supposed to return a letter grade. He feels confident his program is correct because he has tested it using the scores 3, 29, and 67. Sally believes the program is incorrect because she tested the values 73 and 86. The code is syntactically correct, and the programs runs without generating an error, but the results are sometimes wrong. Why does the procedure return the correct values for Jimmy's tests but not Sally's?

+2
Answers (1)
  1. 2 September, 15:46
    0
    There must be a logical error while checking the score

    Explanation:

    Jimmy claims that the program works fine, but he did not test the values that are above 67. When Sally tested 73 and 86, which are greater than 67, she gets an error.

    Sally claims that the program does not work, but she did not test the values that are below 73.

    These imply that Jimmy made a logical error when he compared the values that are greater than 67.
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “Jimmy wrote the procedure scoreToGrade which accepts as a parameter score - a quiz score in the range 0-100. The procedure is supposed to ...” in 📙 Computers & Technology if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers