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
|
int main() //main function
{
Student A();
Student B(4);
Student C("Joe", 40, 5);
A().setName("Tom");
A().setID(200);
A().setID(20);
A().setScore(0, 75);
A().setScore(1, 85);
A().setScore(2, 95);
B.setName("John");
B.setID(30);
B.setScore(0, 70);
B.setScore(1, 80);
B.setScore(2, 90);
B.setScore(3, 100);
C.setScore(0, 90);
C.setScore(1, 91);
C.setScore(2, 92);
C.setScore(3, 93);
C.setScore(4, 94);
C.setScore(5, 95);
C.setScore(4, 105);
C.setScore(-5, -105);
A().display();
B.display();
C.display();
system("Pause");
return 0;
}
|