I cant find any error in my code and also i dont want to see the input. I tested on custom inpputs and it is working perfectly.
#include
using namespace std;
int main() {
int n,carno,r;
cin >> n;
for (int i=0; i<n; i++){
cin >> carno;
int temp=0;
while(carno!=0){
r=carno%10;
temp=temp+r;
carno/=10;
}
if((temp%2==0 && temp%4==0) || (temp%2!=0 && temp%3==0)){
cout << "Yes\n";
}
else {
cout << "No\n";
}
}
return 0;
}