#include <iostream>
#include <cstring>
using namespace std;
char findSingleChar(string s) {
int count[26] = {0}; // 记录每个字符出现的次数,初始化为0
for (int i = 0; i < s.length(); i++) {
count[s[i] - 'a']++;
}
for (int i = 0; i < s.length(); i++) {
if (count[s[i] - 'a'] == 1) {
return s[i];
}
}
return -1; // 如果不存在符合条件的字符,返回-1
}
int main() {
string s;
cin >> s;
char result = findSingleChar(s);
if (result == -1) {
cout << "-1" << endl;
} else {
cout << result << endl;
}
return 0;
}