题解 | 不要三句号的歪
不要三句号的歪
https://www.nowcoder.com/practice/7cbb7d96fb354f7995d9af1ccf8906b4
#include <iostream> using namespace std; int main() { int a; cin >> a; string str; getline(cin, str); int i = str.size() - 1; string c = ""; while(isdigit(str[i])) c = str[i--] + c; cout << stol(c) - a - 2 << endl; return 0; } // 64 位输出请用 printf("%lld")