Hi , every one know the famous hanoi prolog
and you can find it HERE
and its great but when i write this query move(3,left,right,center).
its not showing these results
Move top disk from left to right
Move top disk from left to center
Move top disk from right to center
Move top disk from left to right
Move top disk from center to left
Move top disk from center to right
Move top disk from left to right
what i got is
Trace: >> RETURN: nl()
Trace: >> RETURN: hanoi(1,left,right,center)
Trace: >> RETURN: hanoi(2,center,right,left)
Trace: >> RETURN: hanoi(3,left,right,center)
True
1 Solution
so how i can let it print the results in a better way , and is it possible to name the disks so the program will name them to me as to show results as the following "move disk A from the left to the right"
sorry if I ask a lot but god I love PROLOG.