created for loop and break/contnue - js