how do I show steps of tower of hanoi in table form using sas 9.4?

Reply
New Contributor
Posts: 2

how do I show steps of tower of hanoi in table form using sas 9.4?

hello there. I am a new learner of SAS 9.4. recently, my assignment requires me to create coding, showing the movement of solving the tower of hanoi using array and macro. I totally have no idea of how the iteration should look like. Can anyone lend me a hand?

The output table should be like this for moving 2 disks from rod1 to rod3:

obs   rod1   rod2   rod3   count

1                     1                   1

2                               2         2

3                               1         3

Super Contributor
Super Contributor
Posts: 266

Re: how do I show steps of tower of hanoi in table form using sas 9.4?

Posted in reply to kellyshum
New Contributor
Posts: 2

Re: how do I show steps of tower of hanoi in table form using sas 9.4?

Posted in reply to kellyshum
That is very useful. Thank you so much
Ask a Question
Discussion stats
  • 2 replies
  • 423 views
  • 1 like
  • 2 in conversation