#include<iostream> using namespace std; void is_HuiWenShu(int c) { int n = 0; int m = c; while (m != 0) { n = n * 10 + m%10; m = m / 10; } if (n == c) cout << "yes" << endl; else cout << "no" << endl; } int main() { int num,a,b; cin >> a >> b; num = a + b; is_HuiWenShu(num); return 0; }
原文地址:https://www.cnblogs.com/zhanghua-322/p/11302413.html
时间: 2024-10-25 17:00:02