Colors in Mars
不要忘了10-12用的是ABC…
解答:
#include<iostream>
#include<string>
using namespace std;
int main(){
int red,green,blue;
char book[14]="0123456789ABC";
cin>>red>>green>>blue;
string ans;
ans+=book[red/13];
ans+=book[red%13];
ans+=book[green/13];
ans+=book[green%13];
ans+=book[blue/13];
ans+=book[blue%13];
cout<<'#'<<ans;
return 0;
}