com.github.dakusui.lisj.func.math.Mul Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jcunit Show documentation
Show all versions of jcunit Show documentation
Automated combinatorial testing framework on top of JUnit
package com.github.dakusui.lisj.func.math;
import java.math.BigDecimal;
import com.github.dakusui.lisj.Context;
public class Mul extends NumericFunc {
/**
* Serial version UID.
*/
private static final long serialVersionUID = 8059283467791114034L;
@Override
protected BigDecimal bigDecimalsEvaluateLast(Context context, BigDecimal[] evaluatedParams) {
BigDecimal ret = BigDecimal.ONE;
for (BigDecimal cur : evaluatedParams) {
if (ret == null) ret = cur;
else ret = ret.multiply(cur);
}
return ret;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy