cycle example modified