title: Sudoku Checker Java
body: <p>I have a question about a problem I'm having with a code i am writing. I need to create a Sudoku board checker. The goal is to extend the Sudoku class (to make the CheckableSudoku class) by using the the 5 specific methods I have to use public boolean checkAll( ) to check all of the methods and return true if they pass. Heres my code! Sorry if i explained this too confusingly :/</p>
  
  <pre><code>import java.util.Scanner;
  public class CheckableSudoku extends Sudoku
  {
      public int getCell(int xColumn, int yRow)
      {
          return this.board[xColumn][yRow];
      }
  
      public boolean checkRow (int yCoord)
      {
          int sum = 0;
  
          for ( int x = 0; x &lt;9; x++)
          {
              sum = sum + getCell (x,yCoord);
          }
      return( true );
      }
  
      public boolean checkColumn (int xCoord)
      {
          int sum = 0;
          for (int y = 0; y &lt; 9 ;y++)
          {
              sum = sum + getCell (xCoord, y);
          }
          return( true );
      }
  
      public boolean checkBlock (int col0to2, int row0to2)
      {
          int sum = 0;
          for (int x=0; x&lt;3; x++)
          {
              for (int y=0; y&lt;3;y++)
              {
                  sum = sum + getCell (col0to2+x, row0to2+y);
              }
          }
          return( true);
      }
  
      public boolean checkAll()
      {
      // this is the method that checks all the other methods above
      return true;
      }
  
      public static void main(String[] a)
      {
          CheckableSudoku me = new CheckableSudoku();
          Scanner sc = new Scanner(System.in);
          me.read(sc);
          System.out.print(me);
  
          System.out.println(me.checkAll());
      }
  }
  </code></pre>