Skip to content

Commit 6c2e99b

Browse files
committed
update polygon printing
1 parent c8175dc commit 6c2e99b

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

src/main/java/com/mindee/geometry/Point.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,9 @@ public boolean equals(Object object) {
3535
public int hashCode() {
3636
return x.hashCode() + y.hashCode();
3737
}
38+
39+
@Override
40+
public String toString() {
41+
return String.format("(%s,%s)", x, y);
42+
}
3843
}

0 commit comments

Comments
 (0)