in reply to Using perl to teach programming

Why only 32 levels of undo, especially if you're using an array as a stack? Zero, one, or infinite levels of undo is probably the best way to go. Check out the "command" design pattern for ideas. You could also easily add redo.

Replies are listed 'Best First'.
Re: Re: Using perl to teach programming
by Falkkin (Chaplain) on Jan 31, 2001 at 04:36 UTC
    I intended for the levels of undo to be configurable. Upon further thought, I think I'll make the default be 256 levels.

    Thanks for the suggestion on redo... I'll definitely want to implement that.