我已经看遍了,但无法弄清楚这一点。你如何总结 BigIntegers 的列表?
Using System.Numerics;
Using System.Linq;
List<BigInteger> bigInts = new List<BigInteger>();
BigInteger sum = bigInts.Sum(); // doesn't work
BigInteger sum = bigInts.Sum<BigInteger>(); // doesn't work
BigInteger sum = bigInts.Sum(x => x); // doesn't work
你必须这样做吗?
BigInteger sum = new BigInteger(0);
foreach(BigInteger bigint in bigInts)
sum += bigint;