> 
> >How about this? I think this is the classic recursive solution.
> 


That looked good, and works in Director too. Given that you can call it from 
the message box (or message window in the case of Director), and Director 
doesn't need the 'end' part for handlers, it can be as short as this:

on tower N, start, destination, spare
 if N = 0 then return 
 tower N - 1, start, spare, destination
 put "Move " & N & " from "& start & " to "& destination
 tower N - 1, spare, destination, start
_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Reply via email to