Answered step by step
Verified Expert Solution
Question
1 Approved Answer
can you fix my documantation with the following requirments and add two classes that will be inherited by UndergraduateStudent class and two that will be
can you fix my documantation with the following requirments and add two classes that will be inherited by UndergraduateStudent class and two that will be inherited by PostgraduateStudent class. Also give me the figure of the tree with the levels of classes :Uses at least a threelevel hierarchy of classes exploring inheritance, where at least one
function is polymorphic virtual and the polymorphic properties are essential for the driver
program.
Loads the initial data from input files as opposed to having it hardcoded in the driver
program.
Uses data structures to organize collections of objects, eg single collection of different kind
of objects organized by exploring the polymorphic definition of the behavior of the different
objects.
Uses algorithms to manipulate collections with evaluated and optimal algorithm quality.
You may choose data structures among the studied during the course. In that case, you do not need to
perform algorithms performance evaluation.
You must use effective algorithms as studied in class. For example, using bubble sort or any other ON
algorithms will result immediately with lower grade for the entire project
And here is the documentation:I am going to create a Student Record System that manages information about students, their courses, and grades.
Class Hierarchy:
I am going to design a base class Student with attributes like student ID name, and contact details:
Properties:
studentID A unique identifier for the student eg string or integer
name The student's full name eg string
contactDetails A structure or class holding contact details like email, phone number, etc. eg dictionary or custom class
Methods:
displayDetails Virtual function to return a string containing the essential information about the student, like their ID name, and contact details.
Polymorphism
In my code, you'll notice the displayDetails method, showcasing the concept of polymorphism. I've declared it as virtual in the base class and overridden it in the derived classes. This setup enables the system to choose the right method depending on the object's class during runtime
After that, I will derive two classes from Student: UndergraduateStudent and PostgraduateStudent. Each class should have specific properties related to their student type. I am going to override the displayDetails function in each derived class to include typespecific details.
Properties UndergraduateStudent:
Inherits studentID, name, contactDetails from Student.
Additional properties specific to undergraduate students, eg program, year.
Properties PostgraduateStudent:
Inherits studentID, name, contactDetails from Student.
Additional properties specific to postgraduate students, eg researchArea, supervisor.
Methods for both:
displayDetailsWill override the base class method to include additional details specific to the student type, such as their program or research area.
I will introduce a thirdlevel class StudentRecordManager that manages and processes the student records. This class can handle operations like searching for students based on certain criteria within their descriptions.
Properties:
students A collection eg vector or array to hold objects of type Student which can include both UndergraduateStudent and PostgraduateStudent objects.
Methods:
addStudentStudent Add a new student record to the collection.
Data Loading:
I am going to import student data from input files, each of which corresponds to a distinct student type postgraduate or undergraduate A student's details can be represented by each line in the file.
Data Structures:
To arrange student collections, I will use data structures like vectors or arrays. To enable the application to manage both kinds of students with ease, I am going to create a single collection that can hold objects of the basic class, Student.
Algorithms:
To manipulate student records, I will implement algorithms in the StudentRecordManager class. Then, I will sort students according to their ID or GPA, for example, this can be accomplished by using sorting algorithms. I am going to create a search algorithm that examines the displayDetails output to locate particular students in the collection based on predetermined standards. I will also implement sorting algorithms within sortStudentsby to organize student records efficiently. I am planning to use standard algorithms like quicksort or mergesort based on the attribute.
User Interaction:
I am going to create a straightforward Student Record System user interface. I will give users the ability to search for students, add new students, remove existing students, and view the complete student database. This system will be practical and accessible because to its userfriendly interface.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started