-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
54 lines (34 loc) · 1.41 KB
/
Copy pathmain.cpp
File metadata and controls
54 lines (34 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
#include <iostream>
#include "carbeiter.h"
#include "cverkaeufer.h"
#include "CManager.h"
#include "abteilung.h"
using namespace std;
int main() {
carbeiter *ich;
ich = new carbeiter(80, "Tim Tom", 40, 50.0);
cout << "\n*******************************************" << endl;
cout << ich->toString() << endl;
cout << "Mein Alter: " << ich->getAlter() << endl;
cout << "Mein Gehalt: " << ich->getGehalt() << endl;
cout << "\n*******************************************" << endl;
auto du = new cverkaeufer(20, "Rakek", 20, 25.0, 10, 0.5);
cout << du->toString() << endl;
cout << "Dein Alter: " << du->getAlter() << endl;
cout << "Dein Gehalt: " << du->getGehalt() << endl;
cout << "\n*******************************************" << endl;
auto CEO = new CManager(56, "Picard", 403);
cout << CEO->toString() << endl;
cout << "Dein Alter: " << CEO->getAlter() << endl;
cout << "Dein Gehalt: " << CEO->getGehalt() << endl;
cout << "\n*******************************************" << endl;
cout << "\n*******************************************" << endl;
abteilung *TheOffice = new abteilung("Apple");
TheOffice->addMitarbeiter(ich);
TheOffice->addMitarbeiter(du);
TheOffice->addMitarbeiter(CEO);
cout << TheOffice->toString() << endl;
cout << TheOffice->getGesamtGehalt() << endl;
cout << endl << endl;
return EXIT_SUCCESS;
}