仅供参考,举报我全家四
#include <bits/stdc++.h> using namespace std; int n , x , y; int main() { cin>>n; for(int i = 1 ; i<=n ; i++) { cin>>x; while(x) { y+=x%10; x/=10; } if(y%7==0) cout<<"Yes"<<endl; else cout<<"No"<<endl; y = 0; } return 0; }