Skip to content

Commit 5df2dbe

Browse files
committed
added break on complete to solve_hanoi
1 parent ff14d96 commit 5df2dbe

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

tests/test_maker.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -302,6 +302,8 @@ def solve_hanoi(state: GameState):
302302

303303
state = state.apply(step)
304304
state.visualise()
305+
if state.is_done():
306+
break
305307

306308

307309
logging.basicConfig(

0 commit comments

Comments
 (0)