Run ID:132036
提交时间:2025-10-04 16:22:43
#include <iostream> using namespace std; int main() //不是自定义函数,必须写成main主要的 { int abc; cin >> abc; int a = abc/100 ; // 127 的百位数 int c = abc%10 ; //C++长眼睛 c是个位数 int b = abc/10%10; // cout<< "a="<< a << endl ; // cout<< "b="<< b << "\n" ; // cout<< "c="<< c <<endl ; 选中这三行,按快捷键ctrl + ? 快速注释 cout << a+b+c; return 0; }