【Basic Level】
*1022 边界值输出 0
#include <iostream>
#include <string>
using namespace std;
int main()
{
long long a , b;
unsigned int d;
string s;
cin >> a >> b >> d;
int c = a + b;
if (c == 0)
cout << '0';
while (c != 0)
{
/* code */
s = to_string(c % d) + s;
c = c / d;
}
cout << s << endl;
return 0;
}