题目描述

Create a class called Student that includes four pieces of information as data members—a first name (type string), a last name (type string), a student ID (type int), and monthly scholarship (type int). Your class should have a constructor that initializes the four data members. Provide a set and a get function for each data member. If the student ID or scholarship is not valid (e.g. negative number), set it to 0. Write a test program that demonstrates class student’s capabilities. Create two student objects and display each object’s name, ID, and scholarship. Then give each student a 10 percent raise and display each student’s monthly scholarship again.


输入格式

The input of each line is the information for one student.
You only get the information from two students.
Earh Line:
FirstName LastName ID scholarship


输出格式

1_FirstName 1_LastName
1_ID 1_scholarship
2_FirstName 2_LastName
2_ID 2_scholarship
1_scholarshipAfterRaising
2_scholarshipAfterRaising


样例数据

输入

Jielun Zhou 12 55
Meimei Han 2 10

输出

Jielun Zhou
12 55
Meimei Han
2 10
60
11

备注

Use Student Class


操作

评测记录

优秀代码

信息

时间限制: 1s
内存限制: 128MB
评测模式: Normal

题解