0% found this document useful (0 votes)
47 views4 pages

Object Oriented Programming (OOP) - C++ Open Ended Lab (Updated)

THE OOP LAB PROJECTS

Uploaded by

qaddosskhan920
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)
47 views4 pages

Object Oriented Programming (OOP) - C++ Open Ended Lab (Updated)

THE OOP LAB PROJECTS

Uploaded by

qaddosskhan920
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
You are on page 1/ 4

Sarhad University, Peshawar

Dept. of CS&IT
Open Ended Lab
Assignment # OEL
Subject Name: Object-Oriented Programming (OOP)
Semester: Spring 2025 (2nd) Marks:
Assigned on: 4-08-2025 Submission Due Date: 27-08-2025

CLO-1: Problem Analysis (GA-2)


CLO-2: Design & Development of Solutions (GA-4)
Taxonomy Level: 5 (Design, Analysis and Evaluation)

Introduction
An Open-Ended Lab (OEL) is a special type of assignment where students are given a general problem
idea, but they are free to design and implement their own solution. Unlike traditional labs, which
follow fixed steps, OELs encourage:
 Independent thinking and creativity.
 Application of Object-Oriented Programming (OOP) principles.
 Modeling small real-world scenarios using classes and objects.
The purpose of this OEL is to strengthen students’ understanding of OOP in C++ by applying
concepts such as Encapsulation, Inheritance, Polymorphism, and Abstraction in small, practical
programs.

Note: You may work individually or in groups of up to three students. Collaboration is encouraged, but
each member must contribute to both design and implementation.

Problem Statement
Students are required to select a small real-world inspired problem domain and implement it in C++.
The program should be menu-driven and must apply at least three core OOP principles.

Suggested Problem Domains (choose any one or a similar idea):

🔢 Math & Utility Based


1. Scientific Calculator – Support +, −, ×, ÷, power, square root, factorial (store last 5 results).
2. Unit Converter – Convert between km↔miles, Celsius↔Fahrenheit, kg↔pounds.
3. Matrix Operations – Addition, subtraction, multiplication.
4. Number System Converter – Convert between decimal, binary, octal, hexadecimal.
5. Equation Solver – Solve quadratic equations with coefficients.

👤 Personal / Daily Life


6. Contact Book – Add, search, delete contacts (name, phone).
7. To-Do List – Add, mark complete, delete tasks.
8. Password Manager (basic) – Store usernames and passwords (in memory).
9. Expense Tracker – Add expenses, calculate total & monthly summary.
10. Daily Journal – Add notes, view notes by date (optional file handling).
🎓 Student & Education
11. Student Marks Manager – Enter marks for 3 subjects, calculate average & grade.
12. GPA Calculator – Enter course names, credit hours & grades → calculate GPA.
13. Quiz System – Present MCQs from a small set, calculate score.
14. Library Mini System – Issue/return 2–3 books only.
15. Course Registration – Students register for limited courses, display summary.

💰 Finance & Shopping


16. ATM Mini System – Deposit, withdraw, check balance (1–2 accounts).
17. Bank Account Hierarchy – Classes for Savings & Current accounts.
18. Shopping Cart – Add items with price & quantity, calculate total bill.
19. Café Billing System – Menu with tea, coffee, snacks → customer’s bill.
20. Loan Calculator – Enter principal, rate, time → calculate EMI.

🚗 Objects & Real-Life Systems


21. Vehicle Manager – Add cars/bikes, display details (inheritance).
22. Shape Calculator – Classes for Circle, Rectangle, Triangle → area/perimeter (polymorphism).
23. Employee Payroll System – Calculate salary & bonus for different employee types.
24. Ticket Booking System (mini) – Book bus/train tickets (name, seat no.).
25. Game Scoreboard – Track player names and scores (highest scorer highlighted).
👉 Students may also propose their own small idea with instructor’s approval.

Core OOP Concepts to Apply


 Classes & Objects
 Constructors & Destructors
 Encapsulation & Abstraction
 Inheritance (Single / Multi-level / Hierarchical)
 Polymorphism (Compile-time & Run-time)
 Exception Handling
 File Handling (Optional – for data storage & retrieval)

Objectives
By completing this assignment, each student/group will be able to:
1. Identify and analyze a small-scale real-world problem suitable for OOP implementation.
2. Design a class hierarchy that demonstrates inheritance and polymorphism.
3. Apply encapsulation to secure data and abstraction to hide implementation details.
4. Implement a menu-driven program in C++ demonstrating the designed solution.
5. Use exception handling to manage invalid inputs gracefully.
6. (Optional) Incorporate file handling for persistence.

Implementation Requirements
The developed program must include:
1. Data Input – User-friendly prompts for entering information.
2. Data Management – At least two operations: Add & View (Modify/Delete optional).
3. Data Display – Show stored data in a clear format (tables, lists, reports).
4. Exception Handling – Handle invalid inputs and prevent program crashes.
5. Optional Features – Search/filter functionality or saving data to files (CSV/TXT/JSON).
Deliverables
Each student/group must submit the following:
1. Report (PDF/DOCX):
o Short problem description.
o OOP concepts applied.
o Simple class diagram.
o Screenshots of program execution.
2. Source Code (C++):
o Properly indented and commented.
3. Demonstration (in Lab):
o A short walkthrough of the program.

Data Storage Options


 In-Memory Storage: Suitable for small datasets (lost when program ends).
 File Storage (Optional): For persistence (text, CSV, JSON, etc.).
Students must justify their choice of storage method in the report.

Evaluation Criteria (Marks Distribution – Marks)


Component Marks Description
Problem Understanding & Identifying and justifying the chosen scenario
Analysis
OOP Concept Application Use of classes, inheritance, polymorphism,
encapsulation, abstraction
Program Functionality Execution, menu-driven features, and usability
Short Report & Problem description, class diagram, screenshots
Documentation

Deliverables
1. Report (PDF/DOCX):
o Problem description & scope
o OOP concepts applied
o Class diagrams / hierarchy design
o Features implemented
o Justification of design choices
o (Optional) Screenshots of execution
2. Source Code: Properly documented and well-structured.
3. Demonstration: PPT slides or a short walkthrough of the program.

Design Considerations
Students must ensure that their solution demonstrates:
 Correct application of OOP principles in C++.
 Error handling for invalid inputs.
 Efficiency, maintainability, and scalability.
 Error handling and user-friendly interaction.
 Creativity in choosing and modeling the problem.

--End of Assignment--
Attributes Conformance

S#
Present
Attribute in the
Problem

1 Range of conflicting requirements: The assignment introduces challenges such as Yes


applying multiple OOP principles (inheritance, polymorphism, encapsulation), designing
class relationships, handling input validation, and optionally using file management.
These may conflict (e.g., balancing simplicity vs. complexity).

2 Depth of Analysis required: There is no single fixed solution. Students must analyze their Yes
chosen problem domain and creatively design classes, methods, and relationships using
OOP concepts.

3 Depth of knowledge required: Requires understanding of basic to intermediate OOP Yes


principles in C++, including class design, constructors, inheritance, and polymorphism.
Students demonstrate problem-solving and code organization.

4 Familiarity of issues: Students may encounter challenges for the first time such as Yes
designing class hierarchies, applying abstraction, and handling invalid inputs. These are
new compared to structured labs but aligned with 2nd semester level.

5 Extent of applicable codes: The assignment remains within the scope of standard Yes
computing practices expected at the undergraduate level (C++ programming, OOP
principles). No professional/industry-level standards are required.

6 Extent of stakeholder involved: The assignment is designed for individual students (or No
small groups) and does not involve external stakeholders. Stakeholder complexity is
minimal.

7 Consequences: The consequences are educational only—students improve Limited


understanding of OOP, design, and implementation. Unlike large-scale systems, real-
world resource mismanagement is not a factor.

8 Interdependence: Each chosen system may include multiple components/classes that Yes
work together (e.g., Account, Customer, Transaction). Students must ensure components
interact correctly.

You might also like