In the main function use your classe to create object and demonstrate their functionality, see the screen-shot below:
• Instantiate an object of type Marks
• Prompt the user to enter the four assessments (Class & Cycle tests) and set the object using the setValues method
• Get the predicate to see if the student qualifies to write the exam, if the student does not qualify, display the predicate and show appropriate messages.
If the student qualifies to write the exam, prompt the user to enter the exam mark, set the exam mark on your object and display the final mark and result.
Comments
Leave a comment