#include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; #define REP(i,n) for(int i=0; i=b; --i) #define ALL(c) (c).begin(), (c).end() typedef long long ll; typedef vector VI; typedef vector VL; typedef vector VVL; typedef vector VVI; typedef pair P; typedef pair PL; int main() { string s; cin >> s; int a[26] = {}; for (char c : s) a[c - 'a']++; string ans; REP(i,26){ if (a[i] > 2){ cout << "Impossible" << endl; return 0; } if (a[i] == 1){ ans += i + 'a'; } } cout << (ans.length() == 1 ? ans : "Impossible") << endl; return 0; }