Repository dedicated for the Object Oriented Programming course in ITI with Eng. Mahmoud Ouf and Eng. Muhammad Al-Gindy
- Write Structure Employee (ID, Name, and Salary).
- Make a pointer to the structure and allocate it with a number read by the user.
- Fill the allocated array and then print it.
- Make a function with default argument values and use it.
- Try the scope operator.
- Convert your Employee structure to a class and all its data will be private(the name will be char *).
- Write setter and getter for each property in your class (it must be public).
- Write a swap function that takes a reference for two variables and swaps values.
- Try function overloading and inline function.
- Write three constructors for your Employee class as you like.
- Write the destructor of your Employee class.
- Write the copy constructor of your Employee.
- Write 2 functions with the following prototype:
- Employee FillEmp (int id, int Sal, char * name)
- void PrintEmp (Employee emp)
- Trace your program using f7 key.
- Overload the +, =, ==, int, char *operators to do the following:
- Emp +Emp
- 1000 +Emp
- Emp+1000
- ”Ahmed”+Emp
- Emp+”Ahmed”
- (int)Empreturns Employee id
- (char *)Empreturns Employee name
- Add a class variables for your Employee
- CompanyName -> with setter and gettter.
- EmployeeConut -> with getter only (you know when to increment and decrement that count).
- Create an array for Employee using different constructors for the array elements.
- Write a class point.
- Write a class Rectangle that HAS 2 points.
- Write a member function in the Rectangle that gets its area.
- Write a class circle that knows 2 points and has radius as a member data with its constructors as you like.
- Write setters for circle’s points.
- Write a member function of class circle to get its radius (use Pythagorean Theorem).
- Try to deal with your circle class in the main.
- Write a person class that has id and name with setters and getters.
- Write Employee class that inherits person