a = eval(input())

print(('A' if a.lower()!=a else 'a'))
print(('A' if input().isupper() else 'a'))
a = eval(input())
print(("A" if a.lower() != a else "a"))

print(("A" if input().isupper() else "a"))

-a = eval(input()) -print(("A" if a.lower() != a else "a")) +print(("A" if input().isupper() else "a"))