题目描述
There are 100 questions in a paper. Each question carries +3 marks for correct answer, -1 marks for incorrect answer and 0 marks for unattempted question.
It is given that Chef received exactly X (0 ≤ X ≤ 100) marks. Determine the minimum number of problems Chef marked incorrect.
------ Input Format ------
- First line will contain T, number of test cases. Then the test cases follow.
- Each testcase contains of a single integer X, marks that Chef received.
------ Output Format ------
For each test case, output the minimum number of problems Chef marked incorrect.
------ Constraints ------
$1 ≤ T ≤ 100$
$0 ≤ X ≤ 100$
----- Sample Input 1 ------
4
0
100
32
18
----- Sample Output 1 ------
0
2
1
0
----- explanation 1 ------
Test Case $1$: It might be possible that Chef didn't attempt any question in which case he didn't get any question incorrect.
Test Case $2$: For the case when Chef got $34$ questions correct and $2$ questions incorrect, Chef marked minimum incorrect questions.
Test Case $3$: For the case when Chef got $11$ questions correct and $1$ question incorrect, Chef marked minimum incorrect questions.
Test Case $4$: For the case when Chef got $6$ questions correct and no question incorrect, Chef marked minimum incorrect questions.
输入格式
见题面
输出格式
见题面