2 条题解
- 
  1
包对AC
#include<queue> #include<math.h> #include<stdio.h> #include<iostream> #include<vector> #include<iomanip> #include<string.h> #include<algorithm> #include<cmath> #include<cstdio> #include<utility> #include<cstring> #include<stack> #include<fstream> #include<string> using namespace std; typedef long long ll; const int N = 1e5 + 10; const int INF = 0x3f3f3f3f; string s; long long c , x , ans = 0 , p = 1; int main() { cin>>s; c = s.size() - 1; for ( int i = c ; i >= 0 ; i-- ) { if ( s[i] >= '0' && s[i] <= '9' ) { x = s[i] - '0'; } else if ( s[i] >= 'A' && s[i] <= 'Z' ) { x = s[i] - 'A' + 10; } else { x = s[i] - 'a' + 10; } ans += x * p; p *= 16; } cout << ans; return 0; } 
信息
- ID
 - 1214
 - 时间
 - 1000ms
 - 内存
 - 128MiB
 - 难度
 - 6
 - 标签
 - (无)
 - 递交数
 - 73
 - 已通过
 - 23
 - 上传者