| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 118392 | 付明澄 | 十进制转d进制 | C++ | Accepted | 100 | 0 MS | 260 KB | 270 | 2023-12-30 10:42:17 |
#include<bits/stdc++.h> using namespace std; const string R="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ"; int x; void tox(int n) { if(n/x==0) { cout<<R[n]; return; } tox(n/x); cout<<R[n%x]; } int main() { int n; cin>>n>>x; tox(n); return 0; }