This commit is contained in:
Gnieark 2017-11-22 19:15:26 +01:00
parent bd400745dd
commit d0470ecc4b

View File

@ -1,6 +1,6 @@
<?php <?php
$discCount = 6; $discCount = 3;
//load the class //load the class
include("class.towers.php"); include("class.towers.php");
@ -14,7 +14,7 @@ function resolveHanoi(Tower $tower, Steps $steps){
$result = false; $result = false;
if($tower->is_won()){ if($tower->is_won()){
echo "\nSolution founded. Reverse this steps:\n".$tower; echo "\nSolution founded. Reverse these steps:\n".$tower;
return true; return true;
} }
$availablesMoves = $tower->list_moves_availables(); $availablesMoves = $tower->list_moves_availables();