| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 155262 | 陈骏睿 | 十进制转R进制 | C++ | Wrong Answer | 1 MS | 272 KB | 521 | 2026-06-06 12:18:57 |
#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() #include<cmath> //sqrt()\pow()\abs()\ceil()\floor()\max()\min() using namespace std; int main(){ int a,x,y,i=0; char er[33]={}; cin>>a>>x; if(a==0)cout<<0; while(a!=0){ y=a%x; if(y>=0&&y<=9) er[i++]=char(y+'0'); else er[i++]=char(y+'0'); a/=x; } for(int j=i-1;j>=0;j--)cout<<er[j]; return 0; }
------Input------
8902345 15
------Answer-----
BACAEA
------Your output-----
;:<:>: