#K73317. Donation Verification
Donation Verification
Donation Verification
In this problem, you are given a number of donations. Each donation is represented by four integers: money, item_quantity, item_value, and provided_total_value. You need to verify whether the provided total value is equal to (\text{money} + \text{item_quantity} \times \text{item_value}). For each donation, output "CORRECT" if the equation holds, or "INCORRECT" otherwise. This problem tests your ability to handle basic arithmetic operations and input/output processing in a competitive programming setting.
inputFormat
The first line of input contains an integer (M), denoting the number of donations. Each of the following (M) lines contains four space-separated integers: (money), (item_quantity), (item_value), and (provided_total_value).
outputFormat
For each donation, print a single line containing either "CORRECT" if (money + item_quantity \times item_value = provided_total_value), or "INCORRECT" otherwise.## sample
4
100 5 20 200
200 3 50 350
150 10 10 250
300 2 75 450
CORRECT
CORRECT
CORRECT
CORRECT
</p>