题目链接:进制转换_牛客题霸_牛客网
注意点:
stoi的用法
参考这里:C++中stoi函数_weixin_30502965的博客-CSDN博客
#include <iostream>
#include <string>
using namespace std;
int main()
{
string str;
while (getline(cin,str))
{
cout <<stoi(str,0,16) <<endl;
}
return 0;
}