1 条题解

  • 2
    @ 2024-6-26 11:04:15

    #include<bits/stdc++.h> using namespace std; int main(){ int n,r,k=0; char a[1001]; cin >> r >> n; while(n!=0){ int t = n%r; if (t<10){ a[k] = t+'0'; } else{ a[k] = t+55; } k++; n = n/r; } for(int i=k-1;i>=0;i--){ cout<<a[i]; }

    }

    • 1

    信息

    ID
    626
    时间
    1000ms
    内存
    256MiB
    难度
    9
    标签
    递交数
    10
    已通过
    6
    上传者