unify forloop style in main block