Академический Документы
Профессиональный Документы
Культура Документы
1. Write a Program to read a set of names, roll number, date of birth and date of admission of the students in a
school from the keyboard where the date of birth and date of admission consists of 3 members such as day,
month and year as a separate structure and to sort them in ascending order using a structure
2. WAP to perform the following (using menu) arithmetic operations of a complex number using a structure.
a. Addition
b. Subtraction
c. Multiplication
d. Division
3. WAP with a function that intakes 2 date(day, month,year) structures and returns the structure with later date
4. Define a class to represent a bank account:
Data members
a. name of the depositor
b. Account number
c. Type of account
d. Balance amount in the account
Member functions
a. To assign initial values
b. To deposit an amount
c. To withdraw an amount after checking the balance
d. To display name and balance
5. Define a class student with the following specifications:
Private members of class student
a. adno integer
b. name 25 character
c. marks(5 subjects) float
d. ctotal() function to calculate total with float return type
Public member functions
get() fn. to accept values for adno, name, marks and invoke ctotal to calculate total
e. grade() The percentage marks and grade are to be calculated from the above info. Grade is calculated
as follows.
f. percentage marks
grade
g. < 50
F
>=50 < 60
D
>=60 < 75
C
>=75 < 90
B
>=90 < 100
A
show() display all data members on the screen