S = input() if S.count(S[0]) == 0: print(1, S[0]) else: for i in range(1, len(S)): if S[i] != S[0]: print(i+1, S[i]) break