Britech College | Resources

UPDATES, SOURCE CODES AND LECTURE NOTES

CSC113 FINAL EXAM

1. Write a class based from the design below

class Person
+private string fname;
+private string lname;
+private string age;
+private string add;
+private string contact;
GetValues()
Display()

GetValues() is a method that will get values from the user.
Display() is a method that will give the output based from the user input

1.2 Make two objects from this class



2. Make another class name it as Student, the data members are the same with number one. The GetValues() method in this class must be a parameter type. Display() in this class is a method that will give the output based a predefined inputs.

2.2  Make two objects from this class


3. Make two classes Employee and Teacher.
Members for the Employees are:

+id
+name
+address
+gender
GetData()
DisplayData()

Data Members for the employees are
+SalaryPerMo
+NoOfStudents
GetTData()
DisplayTData()

Make the Employee base class  constructor and the teacher as derived class/sub class;





No comments :

Post a Comment