First line contains a integer T denoting the number of test cases.
Next T lines contains a single integer N denoting the floor from which lift is called.
Output T lines containing one character “A” if the first lift goes to N th floor or “B” for the second lift.
0 <= N <= 7
1 <= T <= 100000
5th floor calls, Lift A(3) and Lift B(7) are equidistant from 5, so Lift from lowest floor goes there i.e. A.