From 75293c3446b9dbb47ad4655212c6bfc1a9b062be Mon Sep 17 00:00:00 2001 From: subcrip Date: Mon, 1 Apr 2024 22:49:41 +0800 Subject: [PATCH] backup --- number/mll.cc | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/number/mll.cc b/number/mll.cc index 4ebe5e8..39c5b9c 100644 --- a/number/mll.cc +++ b/number/mll.cc @@ -12,3 +12,13 @@ template struct MLL { void operator/=(const MLL& rhs) { val = (*this / rhs).val; } void operator%=(const MLL& rhs) { val = (*this % rhs).val; } }; + +template +ostream& operator<<(ostream& out, const MLL& num) { + return out << num.val; +} + +template +istream& operator>>(istream& in, MLL& num) { + return in >> num.val; +}