diff --git a/src/showGrid.java b/src/showGrid.java index f08a388..2028f0b 100644 --- a/src/showGrid.java +++ b/src/showGrid.java @@ -5,6 +5,8 @@ private List gridList = new ArrayList(); public void run() { + + //Whatever you want to search for here. Any x or y length. gridList.add(new String[] {"H", " ", " ", "P"}); gridList.add(new String[] {"?", "G", "N", "?"}); gridList.add(new String[] {"L", "A", "?", "S"}); @@ -14,7 +16,10 @@ gridList.add(new String[] {" ", "R", "I", "N"}); gridList.add(new String[] {" ", "I", "K", " "}); - for (int i = 0; i < 1; ++i) { + //First loop through and check for all words it can find. + //Second loop check again to see if the previous check change anything for it. + //Third loop: Same as second loop. + for (int i = 0; i < 3; ++i) { if (!needChecking()) break; System.out.println("Starting round " + (i + 1)); checkGrid(); @@ -83,6 +88,7 @@ } } + //Print current grid-result. for (int i = 0; i < gridList.size(); ++i) { for (int z = 0; z < gridList.get(i).length; ++z) { System.out.print(gridList.get(i)[z]); @@ -133,4 +139,4 @@ } return false; } -} \ No newline at end of file +}