Hanoi-towers/resolver.php
2017-11-17 23:06:00 +01:00

24 lines
412 B
PHP

<?php
$discCount = 6;
//load the class
include("class.towers.php");
$tower = new Tower($discCount);
resolveHanoi($tower);
function resolveHanoi($tower){
//out of recursif if
$availablesMoves = $tower->list_moves_availables();
//don't take moves that will generate an ever used tower configuration
$useful_moves = array();
foreach($availablesMoves as $move){
}
}