a 加 b 的反序表示的数;
# include <cstdio> # include <cstring> int a, b; char s[11]; void init(void) { scanf("%d%s", &a, s); } void solve(void) { b = 0; for (int i = strlen(s)-1; i >= 0; --i) { b *= 10; b += s[i]-'0'; } printf("%d\n", a+b); } int main() { init(); solve(); return 0; }