1077
#include <iostream> using namespace std; int main() { int m,a,c; int g,s,b,q; cin>>a; for(int i=0;i<a;i++){ cin>>m; q=m/1000; b=(m-1000*q)/100; s=(m-1000*q-100*b)/10; g=m-1000*q-100*b-10*s; if(g-q-b-s>0){ c++; }else{ c=c; } } cout<<c; return 0; }