Towers of Hanoi: Difference between revisions

m
Line 498:
I think it is standard pascal, except for the constant array "strPole". I am not sure if constant arrays are part of the standard. However, as far as I know, they are a "de facto" standard in every compiler.
 
<lang pascal> program Hanoi;
<pre>
program Hanoi;
type
TPole = (tpLeft, tpCenter, tpRight);
Line 516 ⟶ 515:
begin
MoveStack(4,tpLeft,tpCenter,tpRight);
end.</lang>
</pre>
 
A little longer, but clearer for my taste
<lang pascal> program Hanoi;
<pre>
program Hanoi;
type
TPole = (tpLeft, tpCenter, tpRight);
Line 545 ⟶ 542:
begin
MoveStack(4,tpLeft,tpCenter,tpRight);
end.</lang>
</pre>
 
=={{header|Perl}}==