Write a C++ program with a class 'student' that has three attributes: name, roll, and marks. Use a get method to input data for two objects. Then…

Write a C++ program with a class 'student' that has three attributes: name, roll, and marks. Use a get method to input data for two objects. Then, find the student with the highest marks and print that student's name.

From the Cadet College Lecturer (ICT) May 2025 – Written exam, question 2 of 10.

More from this paper