From 4661e2d97436bdc599f82e61be3a8fd3f6e04c84 Mon Sep 17 00:00:00 2001 From: filifa Date: Thu, 21 Aug 2025 19:11:14 -0400 Subject: [PATCH] simplify a bit --- cmd/crt.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/cmd/crt.go b/cmd/crt.go index d6c2e09..9ab9986 100644 --- a/cmd/crt.go +++ b/cmd/crt.go @@ -35,12 +35,11 @@ func crt(cmd *cobra.Command, args []string) { ns := make([]*big.Int, len(moduli)) for i := range moduli { - n, ok := new(big.Int).SetString(moduli[i], 10) + var ok bool + ns[i], ok = new(big.Int).SetString(moduli[i], 10) if !ok { log.Fatal("invalid input " + moduli[i]) } - - ns[i] = new(big.Int).Set(n) } // TODO: support non-pairwise coprime moduli