0% found this document useful (0 votes)
5 views3 pages

Assignment 1

This assignment requires students to implement a program using Object-Oriented Programming (OOP) concepts based on personal information, choosing between two scenarios: a National Student Registration System or a Scholarship Management System. Students must create a StudentProfile class with various attributes, implement exception handling, and manage multiple records through a central database class. A report detailing the implementation and justifications for OOP concepts is mandatory, along with the submission of the C++ code.

Uploaded by

mharisajmal10
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views3 pages

Assignment 1

This assignment requires students to implement a program using Object-Oriented Programming (OOP) concepts based on personal information, choosing between two scenarios: a National Student Registration System or a Scholarship Management System. Students must create a StudentProfile class with various attributes, implement exception handling, and manage multiple records through a central database class. A report detailing the implementation and justifications for OOP concepts is mandatory, along with the submission of the C++ code.

Uploaded by

mharisajmal10
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Object-Oriented Programming (OOP)

Complex Computing Problem

Assignment: 1 (CLO-3)
Total Marks: 30
Due Date: 16-04-2025

Objective:
The purpose of this assignment is to apply fundamental OOP concepts in a real-world scenario
where each student will implement a program using their own personal information.

Scenario Options:
Each student must choose one of the following two real-world scenarios for their
implementation:

1. National Student Registration System (NADRA-like)

Imagine a government agency responsible for maintaining a national student registration


system. Each student must create a program that registers and manages their own data in a
structured format. To achieve this, students will define a class StudentProfile that contains
their personal information (their own) as attributes such as full name, university roll number,
degree, city, tehsil, district, province, home address, father's name, and family caste.

A constructor will initialize these details when an object is created, while a destructor will
indicate when an object is removed. Students must ensure data integrity using exception
handling, such as validating that names contain only alphabets and roll numbers are strictly
numeric. Additionally, a constant member function should be implemented to display
information without modifying it.

To ensure data management efficiency, implement shallow and deep copy constructors to
correctly handle object duplication. Overload an operator (e.g., ==) to compare two students
based on roll numbers. Since a student may have multiple addresses (such as permanent and
temporary), use dynamic memory allocation to manage multiple addresses efficiently.
Additionally, maintain a static data member to count the number of StudentProfile objects
created. The Address class should be used within StudentProfile through object composition
to ensure separation of concerns.

A central StudentDatabase class must be implemented to manage multiple student records,


allowing functionalities such as adding new students, searching for students, and displaying all
registered students.
2. Scholarship Management System

Consider a scenario where students apply for government scholarships. Each student must
develop a scholarship management system that maintains their own academic records and
evaluates their eligibility for a scholarship. The core of this system will be a StudentProfile
class, which will store personal details (written in above scenario) along with additional
attributes such as CGPA and family income.

Upon creation, the constructor will initialize these details, while the destructor will signal
when an object is deleted. Exception handling must be used to verify that CGPA values are
within a valid range (0.0 to 4.0) and that income values are non-negative. A constant member
function should be used to display details without modifying them.

To manage multiple scholarship applicants, implement shallow and deep copy constructors to
properly handle object duplication. Overload an operator (e.g., ==) to compare students based
on roll numbers. Since students may have multiple addresses (such as university hostel and
home), use dynamic arrays to store address details. A static data member should count the
total number of students applying for the scholarship. The Address class should be designed
separately and included in StudentProfile through object composition.

A ScholarshipDatabase class will serve as the central management system to handle multiple
student records, enabling operations such as registering students, checking eligibility, and
displaying scholarship recipients.

Report Submission (Mandatory)


Each student must submit a 1-3 page report explaining their implementation. The report must
include justifications for why and how each OOP concept was applied, but full code is NOT
allowed (only 2-4 line snippets for explanation are permitted).

Report Format

Students must follow this format:

1. Cover Page:

 Student Name
 Roll Number
 Course Name
 Assignment Topic Title
2. Introduction (2 Marks)

 Briefly explain the objective of your assignment.


 How does your program implement real-world OOP concepts?

3. Implementation (10 Marks)

 Explain each OOP concept used and justify its use.


 Example structure:
o Concept: Constructor
o Why used? To initialize the student data at object creation.
o Implementation (2-4 line snippet):
o StudentProfile::StudentProfile(string name, int roll) {
o this->name = name;
o this->rollNumber = roll;
o }

4. Conclusion (3 Marks)

 What challenges did you face?


 What did you learn from this assignment?

C++ Code (15 Marks)

 To be submitted as .cpp file along with the word document.

Submission Guidelines:
 Code file (C++ program) must be submitted in .cpp format.
 Report must be submitted in a Word document.
 Ensure that all code and explanations (report) are your own; plagiarism will result in zero
marks.

Good luck!

You might also like