code: public void readPattern(int[] row, int[] column) throws IOException {
          int size = row.length;
          if (size != column.length)
              throw new IllegalArgumentException(
                      "All arrays must be of the same size");
          for (int i = 0; i < size; ++i) {
              row[i] = getInt();
              column[i] = getInt();
          }
      }
docs: Reads a pattern matrix