#include <bits/stdc++.h>

using namespace std;

int main(){
	string s;getline(cin, s);
	int pera, petra;cin >> pera >> petra;
	if(pera == petra){
		for(int i = 0;i < pera;i++){
			cout << s[1] << s[0];
		}
		cout << endl;
	}
	else{
		cout << "nemoguce" << endl;
	}
	return 0;
}