Skip to content

Commit 6792012

Browse files
committed
fix modint
1 parent 8821656 commit 6792012

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

cpp/numbertheory/modint.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,9 @@ struct modint {
5151
return u;
5252
}
5353

54-
bool operator==(modint rhs) { return value == rhs.value; }
54+
bool operator==(modint rhs) const { return value == rhs.value; }
5555

56-
bool operator!=(modint rhs) { return !(*this == rhs); }
56+
bool operator!=(modint rhs) const { return !(*this == rhs); }
5757

5858
friend modint operator+(modint lhs, modint rhs) { return lhs += rhs; }
5959

0 commit comments

Comments
 (0)