#include using namespace std; int main() { string s; cin >> s; vector a(13); for (int i = 0; i < 13; ++i) { a[s[i] - 'a']++; } int cnt0 = 0, cnt1 = 0, cnt2 = 0, ans; for (int i = 0; i < 13; ++i) { switch (a[i]) { case 0: cnt0++; ans = i; break; case 1: cnt1++; break; case 2: cnt2++; break; default: break; } } if (cnt1 == 13) { for (int i = 0; i < 13; ++i) { cout << (char) ('a' + i) << endl; } } else if (cnt0 == 1 && cnt1 == 11 && cnt2 == 1) { cout << (char) ('a' + ans) << endl; } else { cout << "Impossible" << endl; } return 0; }