Question: In C + + language for object oriented programming Q 1 . Create a class named 'Student' with a string variable 'name' and an integer

In C++ language for object oriented programming
Q1.
Create a class named 'Student' with a string variable 'name' and an integer variable 'roll_no'. Assign the value of roll_no as '2' and that of name as "John" by creating an object of the class Student.
Q2. Assign and print the roll number, phone number, and address of two students having names "Sam" and "John" respectively by creating two objects of the class 'Student'.
 In C++ language for object oriented programming Q1. Create a class

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!