#include <iostream>
#include <string>

using namespace std;

int main(){
    string word;
    int count;
    char symbol;

    cout << "Input word: ";
    getline(cin, word);

    count = 0;
    for (int i = 0; i < word.size(); i++){
        for (int j = 0; j < word.size(); j++){
            if (word[i] == word[j]) {
                count++;
            }
        }
        if (count > 1){
            symbol = word[i];
            break;
        }
        count = 0;
    }

    cout << "Result: " << symbol << endl;

    return 0;
}