#include #include #include #include #include #include #include #include #include #include using namespace std; #define int long long int MOD = 1000000007; signed main() { cin.tie(0); ios::sync_with_stdio(false); string S; cin >> S; vector A(26, 0); char res; for (int i = 0; i < 13; i++) { A[(int)(S[i] - 'a')]++; } int c = 0; bool f = true; for (int i = 0; i < 26; i++) { if (A[i] == 1) { c++; res = i + 'a'; } else if (A[i] > 2) { f = false; } } if (c != 1) { f = false; } if (f) { cout << res << endl; } else { cout << "Impossible" << endl; } }