ON 1:LOAD:{ set %maxrand 1 } alias bouclerandom { set %randnum $rand(0,10) set %randtry 0 :depart set %rand1 $rand(0,10) inc %randtry 1 if (%rand1 == %randnum) { echo boucle terminée après %randtry essai(s) ... le maximum est %maxrand if (%randtry > %maxrand) { set %maxrand %randtry } unset %rand1 unset %randnum unset %randtry } else goto depart }