rt
#define IOI return
#define AK 0
#define ME ;
#include <bits/stdc++.h>
using namespace std;
int main(){
int a,b,d=1;
string c;
cin>>a>>b>>c;
while(d++){
int y=0;
for(int i=c.length()-1;i>=0;i--){
if(c[i]-'0'>d)break;
y=y+(c[i]-'0')*pow(d,c.length()-i-1);
}
if(y==a*b){
cout<<d;
break;
}
if(d==16){
cout<<0;
break;
}
}
IOI AK ME
}
有daloa能帮我看一下为啥吗qwq