_,s,_ = input().split()

print(("A"+s[0]+"C"))

S = input().split()

print(("A"+S[1][0]+"C"))
_, s, _ = input().split()
print(("A" + s[0] + "C"))

S = input().split()
print(("A" + S[1][0] + "C"))

-_, s, _ = input().split() -print(("A" + s[0] + "C")) +S = input().split() +print(("A" + S[1][0] + "C"))