P5742 [Shenji 7. Example 11] Rating Levels
Description
There are $N$ 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 $70\%$ and $30\%$, 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** $140$, and the overall score is **not less than** $80$.
> 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 $N$.
The next $N$ lines each contain $3$ integers, which represent the student ID, the academic score, and the quality development score, in order.
Output Format
Output $N$ lines. If the $i$-th student is Excellent, output `Excellent`; otherwise output `Not excellent`.
Explanation/Hint
Constraints: It is guaranteed that $1 \le N\le 1000$. The student ID is a positive integer not exceeding $100000$. The academic score and the quality development score are positive integers between $0$ and $100$.
Translated by ChatGPT 5