#P5742. 【深基7.例11】评等级
【深基7.例11】评等级
Problem Description
There are students. For each student, you need to design a struct to record the following information: student ID, academic score, quality development score, and overall score (a real number). For each line, read the student ID, academic score, and quality development score, and compute the overall score (accumulated with weights of and , respectively), then store everything in the struct. You also need to define a member function in the struct that returns the total score of the academic score and the quality development score for that struct object.
Then design a function whose parameter is a student struct object, and determine whether the student is "Excellent". The definition of Excellent is: the total of academic and quality development scores is greater than , and the overall score is not less than .
Of course, this problem is easy to pass. It is only meant to help you practice how to use structs.
This problem has precision issues. Please convert comparing a * 0.7 + b * 0.3 with 80 into comparing a * 7 + b * 3 with 800.
Input Format
The first line contains an integer .
The next lines each contain integers, which represent the student ID, the academic score, and the quality development score, in order.
Output Format
Output lines. If the -th student is Excellent, output Excellent; otherwise output Not excellent.
4
1223 95 59
1224 50 7
1473 32 45
1556 86 99
Excellent
Not excellent
Not excellent
Excellent
Hint
Constraints: It is guaranteed that . The student ID is a positive integer not exceeding . The academic score and the quality development score are positive integers between and .
Translated by ChatGPT 5