Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Beaucoup de cailloux

Le même principe que tout à l’heure mais un peu plus difficile ! Là encore, la taille du labyrinthe varie !

from laby.global_fr import *
from random import randint

l = randint(1, 20)
carte = "o " + "o " * (l + 3) + "o\n"
carte += "o " + "→ " + ". " + "r " * l + ". " + "x\n"
carte += "o " + "o " * (l + 3) + "o\n"
Laby(carte=carte)
debut()
### BEGIN SOLUTION
avance()
while regarde() == Caillou:
    prend()
    droite()
    droite()
    pose()
    droite()
    droite()
    avance()
avance()
### END SOLUTION
ouvre()
assert est_gagnant()