//------------// Introduction to Programming Using Java: An Object-Oriented Approach//	Arnow/Weiss//------------import java.io.*;import java.util.*;class LifeDisplay {    public LifeDisplay() {        keybd = new BufferedReader(new                             InputStreamReader(System.in));    }    public void displayWorld(boolean[][] world) throws                                                 Exception {        pause();        drawLine(world.length+2);           for (int i = 0; i < world.length; i++) {               System.out.print("|");               for (int j = 0; j < world[i].length; j++)                   drawSquare(world[i][j]);               System.out.println("|");           }           drawLine(world.length+2);    }    private void drawLine(int n) {        for (int i = 0; i < n; i++)           System.out.print("-");        System.out.println();    }    private void drawSquare(boolean s) {        if (s)           System.out.print("*");        else           System.out.print(" ");    }    private void pause() throws Exception {        System.out.print("Hit return to continue ... ");        System.out.flush();        keybd.readLine();    }    BufferedReader keybd;}