Assignment 2

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 1

VNR VIGNANA JYOYHI ENGINEERING COLLEGE, BACHUPALLY

(AUTONOMOUS)
Department Computer Science Engineering
ACADEMIC YEAR: 2021-2022 II YEAR B.TECH I SEMSTER
OBJECT ORIENTED PROGRAMMING THROUGH C++
ASSIGNMENT 2
1. Develop an Application Consider an example of declaring the examination
result. Design three classes: Student, Exam, and Result. The Student class
has data members such as those representing roll number, name, etc. Create
the class Exam by inheriting the Student class. The Exam class adds data
members representing the marks scored in six subjects. Derive the Result
from the Exam class and it has its own data members such as
total_marks.Write an interactive program to model this relationship. What
type of inheritance does this model belong to? (CO3,BL6)
2. Develop an Application Consider that the base class Stack is available. It
does not take care of situations such as overflow or underflow. Enhance this
class to MyStack which raises an exception whenever overflow or underflow
error occurs. (CO4,BL6)

You might also like