S = input() cnt = [S.count(chr(ord("a") + i)) for i in range(13)] if max(cnt) == 2 and cnt.count(0) == 1: print(chr(ord("a") + cnt.index(0))) elif cnt.count(1) == 13: for i in range(13): print(chr(ord("a") + i)) else: print("Impossible")