From 7d118565443fe696c4ffb5ce23b18f92bdfed95f Mon Sep 17 00:00:00 2001 From: subcrip Date: Thu, 28 Nov 2024 14:05:34 +0000 Subject: [PATCH] Update template.cc Signed-off-by: subcrip --- template.cc | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/template.cc b/template.cc index ef5c698..55e1bc6 100644 --- a/template.cc +++ b/template.cc @@ -401,11 +401,11 @@ template struct MLL { friend MLL operator%(const MLL& lhs, const MLL& rhs) { return mod(lhs.val - (lhs / rhs).val, mdl); } friend bool operator==(const MLL& lhs, const MLL& rhs) { return lhs.val == rhs.val; } friend bool operator!=(const MLL& lhs, const MLL& rhs) { return lhs.val != rhs.val; } - void operator+=(const MLL& rhs) { return *this = *this + rhs; } - void operator-=(const MLL& rhs) { return *this = *this - rhs; } - void operator*=(const MLL& rhs) { return *this = *this * rhs; } - void operator/=(const MLL& rhs) { return *this = *this / rhs; } - void operator%=(const MLL& rhs) { return *this = *this % rhs; } + MLL& operator+=(const MLL& rhs) { return *this = *this + rhs; } + MLL& operator-=(const MLL& rhs) { return *this = *this - rhs; } + MLL& operator*=(const MLL& rhs) { return *this = *this * rhs; } + MLL& operator/=(const MLL& rhs) { return *this = *this / rhs; } + MLL& operator%=(const MLL& rhs) { return *this = *this % rhs; } }; template