Need help writting C++ programs to perform the following tasks. In the program d
ID: 3734373 • Letter: N
Question
Need help writting C++ programs to perform the following tasks. In the program descriptions below, example input and output is provided.
• rectangle2.cpp: You should create another rectangle, this time create it as a class. The width and height should be private memebers of the class. You should then write the getArea method as a member function of the class.
You should create and print the same rectangles from before, using class methods.
• student.cpp: You should create a class which represents a student in a university. The class should contain the following members: firstName, lastName, studentId.
The first and last name should be string objects. the studentId should be an unsigned integer.
These members should be private. You should write getters and setters for these.
You should write a constructor which takes the three members as arguments.
You should create and print the following objects:
first last id alice smith 10020 bob smith 20304 jane doe 30405 john doe 30030Explanation / Answer
Following is the Full java Code:
Rectangle.java
RectangleMAin.java
Student.java
StudentMain.java
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.