Question: The method getMark() accepts a student name, the array of student names, the array of test marks, and the test number (e.g., for Test 4,
The method getMark() accepts a student name, the array of student names, the array of test marks, and the test number (e.g., for Test 4, the number will be 4). The method returns the student's mark on that test. If the student is not found, the method returns -1.
The code is shown below. However, it contains one major error. Indicate the statement that contains the error then write the correct statement.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
