#C7145. Alexa's Training Session Plan
Alexa's Training Session Plan
Alexa's Training Session Plan
Alexa wants to design her daily practice sessions such that the number of short sessions is strictly greater than the number of long sessions. Given the total number of practice hours N, determine if it is possible for her to create such a plan.
The decision is based on a hidden rule: if N is equal to 1, 2, or 4, then it is IMPOSSIBLE to formulate a plan that meets the requirement; for any other value of N, it is POSSIBLE to create a valid plan.
For example, if N is 3, 5, 6, etc., then the answer is POSSIBLE. Otherwise, if N is 1, 2, or 4, the answer is IMPOSSIBLE.
Note: Although the problem statement hints at planning with "short sessions" and "long sessions", the decision rule is provided as above.
inputFormat
The first line of input contains an integer T representing the number of test cases. Each of the following T lines contains a single integer N, which represents the total number of practice hours for that test case.
Input Format:
T N1 N2 ... NT
outputFormat
For each test case, output a single line with either POSSIBLE or IMPOSSIBLE. The output should be printed to stdout
in the order of the test cases.
5
2
3
4
5
6
IMPOSSIBLE
POSSIBLE
IMPOSSIBLE
POSSIBLE
POSSIBLE
</p>