Kara läuft solange gerade aus, bis rechts und links von ihm ein Baum ist. Anschliessend läuft er weiter, bis entweder rechts oder links kein Baum mehr ist.
while not (kara.treeLeft() and kara.treeRight()): kara.move() while kara.treeLeft() and kara.treeRight(): kara.move()