#coding:utf-8 import collections def main(): s_list = list(input()) s_dict = collections.Counter(s_list) key = [k for k, v in s_dict.items() if v == 1 ] print(key[0]) if len(s_dict) == 7 else print('Impossible') if __name__ == '__main__': main()