#C2681. Workshop Capacity Checker
Workshop Capacity Checker
Workshop Capacity Checker
This problem requires you to determine whether a workshop is overbooked or not. You are given the capacity C of the workshop and the number of people P who registered. For each test case, if the inequality $P > C$ holds, print "OVERBOOKED"; otherwise, print "AVAILABLE".
Note:
- The first input line contains a single integer T, representing the number of test cases.
- Each subsequent line contains two space-separated integers: C (the maximum capacity), and P (the number of registered attendees).
Output one line per test case with the result.
inputFormat
Input is taken from standard input (stdin). The first line contains an integer T denoting the number of test cases. Each of the next T lines contains two integers C and P separated by a space.
For example:
3 50 60 30 25 15 15
outputFormat
For each test case, output a line to standard output (stdout) that contains either "OVERBOOKED" if the number of registered people is greater than the capacity, or "AVAILABLE" otherwise.
For example:
OVERBOOKED AVAILABLE AVAILABLE## sample
3
50 60
30 25
15 15
OVERBOOKED
AVAILABLE
AVAILABLE
</p>