#include <bits/stdc++.h> using namespace std; int main() { //freopen("numbergame.in","r",stdin); //freopen("numbergame.out","w",stdout); ios::sync_with_stdio(false); int n; cin>>n; cout<<n%9; return 0; }
突然就AC了。。。