S=''.join(sorted(input())) A='abcdefghijklm' o='Impossible' Z=set() for i in range(13): for j in range(13): if A in S[:i]+A[j]+S[i:]: o='' Z.add(A[j]) else: if o:print(o) print('\n'.join(sorted(Z)))