こういう時に注意かな
for(int i=0;i<10;i++) cout << i << endl;
cout << i << endl;

で、いらないテクニックを覚える…と
#define for if(1)for