Sha256: adba2d722ba64ed5d4acfe1f91c40198296b08dd2783ab49c39ea339cc541249

Contents?: true

Size: 588 Bytes

Versions: 61

Compression:

Stored size: 588 Bytes

Contents

class MatrixCoordinate {

  private final int row;

  private final int col;

  MatrixCoordinate(final int row, final int col) {
    this.row = row;
    this.col = col;
  }

  // Generated equals and hashcode.

  @Override
  public boolean equals(final Object o) {
    if (this == o) return true;
    if (o == null || getClass() != o.getClass()) return false;

    final MatrixCoordinate that = (MatrixCoordinate) o;

    return row == that.row && col == that.col;
  }

  @Override
  public int hashCode() {
    int result = row;
    result = 31 * result + col;
    return result;
  }

}

Version data entries

61 entries across 61 versions & 1 rubygems

Version Path
trackler-2.2.1.38 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.37 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.36 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.35 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.34 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.33 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.32 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.31 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.30 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.29 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.28 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.27 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.26 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.25 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.24 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.23 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.22 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.21 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.20 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java
trackler-2.2.1.19 tracks/java/exercises/saddle-points/src/main/java/MatrixCoordinate.java