import java.util.Stack;

public class Board {

    int disks;

    public Board(int count) {
        disks = count;
    }

    public void show(Hanoi hanoi) {
        String pegs = pegs(hanoi);
        CharacterDisplay.render(pegs, disks);
    }

    public void start() {
        CharacterDisplay.message("Playing Hanoi for " + disks + " disks:\n");
    }

    public void done() {
        CharacterDisplay.message("Solved.");
    }

    private String pegs(Hanoi hanoi) {
        String pegs = "";
        for (int i = 1; i <= disks; i++) {
            String row = slot(i, hanoi.peg_1) +
                    slot(i, hanoi.peg_2) +
                    slot(i, hanoi.peg_3);
            pegs = row + "\n" + pegs;
        }
        return pegs;
    }

    private String slot(int level, Stack<Integer> peg) {
        String slot;
        if (peg.size() >= level) {
            int diskSize = peg.get(level - 1);
            slot = CharacterDisplay.drawNumber(diskSize, disks);
        } else {
            slot = CharacterDisplay.drawSpace(disks);
        }
        return slot;
    }
}
@@ -229,24 +229,51 @@
 gs, disks);%0A
+        wait_seconds(1.2);%0A
     %7D%0A%0A    p
@@ -1104,10 +1104,189 @@
 t;%0A    %7D
+%0A%0A    private void wait_seconds(double seconds) %7B%0A        long started = System.currentTimeMillis();%0A        while (System.currentTimeMillis() %3C started + 1000 * seconds) %7B%7D%0A    %7D
 %0A%7D

add short wait to each Hanoi step to make it more fun