s = input() r = "abcdefghijklm" z,o,t = '','','' for x in r: if s.count(x)==0: z+=x elif s.count(x)==1: o+=x else: t+=x if len(z)==len(t)==1: print(z) elif len(z)==len(t)==0: for x in list(o): print(x) else: print("Impossible")