[chuck-users] [oh my god] hanoi.ck

Kassen signal.automatique at gmail.com
Fri Aug 3 05:53:48 EDT 2007

On 8/3/07, 2g <electriclightheads at gmail.com> wrote:
> was to keep quiet for a while but..


was just curious what kind of vietnam sound it would make and did
> chuck hanoi.ck
> !! arrrrgh what is it doing?
> it seems to have moved many files instead of making sound
> sould i undo?
> if yes how do i?

A quick introduction to this Budhist myth.

The idea is that there is supposed to be a temple. In the temple there are
three large pins standing and on one of the pins there are 64 stacked disks,
sorted from large (at the bottom) to small (at the top). The disks have a
hole in them to fit on the pins.

The goal of this puzzle is to move all the disks from one pin (say the left
most) to another (for example the right-most). To do this you may only move
the top disk from one of the pins to another pin but it may never be on top
of a disk smaller then itself. You may know this as a game made in wood
(with 8 or so disks) for small childeren, in this temple it was supposed to
be monks who moved the 64 heavy golden disks around diamond pins. Once the
monks have sucessfully moved all the disks the end of time will come. Try it
with five disks yourself, try it with six next, try to figure out wether you
can determine how many moves it will take as a function of the number of

If you've done that excersise you'll know that those ancient Budhists didn't
believe the "end was quite as nigh" as some other religions have at times
proposed. You'll also realise why this is a puzzle that benefits from being
solved automatically.

Well, many tried that exersise before you, so many in fact that solving "the
towers of Hanoi" automatically is a standard exersise in learning to program
and so it makes sense as a demonstration of how a language works.

As for Vietnamese sounds; you can edit them in and make the algorithem make
sound, for example one pitched note every time a disk is moved determined by
the size of the disk (don't forget to advance time!). Hint; there is a
bamboo chime in the "shakers" Ugen. I'm not intimately familiar with
Vietnamese music but bamboo chimes tuned to the right scale might be a good
bet, considdering that Vietnam has it's share of bamboo and that it sounds

Happy ChucKing!

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.cs.princeton.edu/pipermail/chuck-users/attachments/20070803/258505f3/attachment-0001.htm 

More information about the chuck-users mailing list