Question: how to write procedures that use go to in Maple

Recently I was looking at an algorithm in one of Knuth's books.

The algorithm is described in steps with many of the form 

if condition 1 then goto step 7; if condition 2 go to step 8, 

etc.

I managed to write up the algorithm by making each step

a procedure, but had trouble with handling global variables.

 

Is there in Maple some standard method for dealing with such algorithms.

A friend tells me  that in some languages there are "cases" and

"switches" that can be used.  Is there any thing like that in Maple?

 

Thanks,

Edwin

Please Wait...