first complex loop