| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 32552 | 董承诺 | 进制转换 | C++ | Accepted | 100 | 0 MS | 248 KB | 265 | 2022-02-11 19:40:15 |
#include<bits/stdc++.h> using namespace std; int x,m,a[100],k; char c[16]={'0','1','2','3','4','5','6','7','8','9','A','B','C','D','E','F'}; int main(){ cin>>x>>m; while(x){ a[++k]=x%m; x/=m; } for(int i=k;i>=1;i--) cout<<c[a[i]]; return 0; }