Submission
Status:
PPPPPPPPPP
Score: 100
User: Ecir
Problemset: Base Converter
Language: cpp
Time: 0.003 second
Submitted On: 2025-03-13 21:13:54
#include <bits/stdc++.h>
using namespace std;
using ll=long long int;
#define twod array<ll,2>
vector<ll> ans;
void walk(ll u,ll v){
if(u==0) return;
walk(u/v,v);
ans.push_back(u%v);
}
int main(){
ios::sync_with_stdio(0);cin.tie(0);
ll x,y;cin >> x >> y;
walk(x,y);
for(auto e:ans) cout << e;
return 0;
}