牛牛 • 3个月前
using namespace std; int main(){
int n,a,s=0; cin>>n; while (n){ a=n%10; s=a+s; n=n/10; } cout<<s; return 0;
}
评论:
请先登录,才能进行评论