Imran Hameed (BC080400629@Vu.edu
2009-06-24 05:58:01 UTC
Semester: Spring 2009
CS201: Introduction to Programming
Total Marks: 20
Due Date:23/06/2009
Instructions
Please read the following instructions carefully before submitting assignment:
It should be clear that your assignment will not get any credit if:
The assignment is submitted after due date.
The submitted assignment does not open or file is corrupt.
All types of plagiarism are strictly prohibited.
Note: You have to upload only .cpp file. Assignment in any other format (extension) will not be accepted. If you will submit code in .doc (Word document) you will get zero marks.
Objective
The objective of this assignment is to provide hands on experience of using
Classes and Objects (Advance)
Guidelines
Code should be properly aligned and well commented.
Follow c/c++ rules while writing variables names, function names etc
Use only dev-C++ for this assignment.
Assignment
Problem Statement:
Write a c++ program which consists of two classes:
1. Date
2. Student
First class Date should contain three data members:
Day
Month
Year
Date also contain following member functions:
Setter function
Getter function
showdate()
Now second class Student should have following three data members:
ST_ID
Name
Ad_date
Where ID and Name are char pointer while Ad_date (Date of Admission) is of type Date.
Student class should contain two member functions:
Display()
setdate()
Now in main function create an object of Class Student and call the member functions with it.
--------------------------------------------------------------------------
Sample output:
Name: Ali
ID: BC020400000
Admission Date: 12-08-2008
Deadline
Your assignment must be uploaded/submitted on or before 23-06-2009