a = eval(input())

if 'A' <= a <= 'Z':

    print('A')

else:

    print('a')
a = eval(input())

if 'A' <= a <= 'Z':

    print('A')

elif 'a' <= a <= 'z':

    print('a')
a = eval(input())
if "A" <= a <= "Z":
    print("A")
else:
    print("a")

a = eval(input())
if "A" <= a <= "Z":
    print("A")
elif "a" <= a <= "z":
    print("a")

-else: +elif "a" <= a <= "z":