#include #include #include #include #include #include #include #include #include #include #include #include #include #define p(s) cout<<(s)<=n;i--) #define CK(n,a,b) ((a)<=(n)&&(n)<(b)) #define F first #define S second typedef long long ll; using namespace std; const int mod = 1e9+7; string s; int C[30]; int main(){ cin>>s; for(auto c:s) C[c-'a']++; string ans="Impossible"; REP(i,0,'z'-'a'+1){ if(C[i]==1) ans = (char) ('a' + i); else if(C[i]==2||C[i]==0) continue; else{ ans="Impossible"; break; } } p(ans); return 0; }