mirror of
https://github.com/Myzel394/NumberHub.git
synced 2025-06-19 00:35:26 +02:00
Remove prints
This commit is contained in:
parent
52a1a5b4d5
commit
d0b09beb7d
@ -301,8 +301,6 @@ private fun BigDecimal.factorial(): BigDecimal {
|
|||||||
if (this.remainder(BigDecimal.ONE).compareTo(BigDecimal.ZERO) != 0) throw ExpressionException.FactorialCalculation()
|
if (this.remainder(BigDecimal.ONE).compareTo(BigDecimal.ZERO) != 0) throw ExpressionException.FactorialCalculation()
|
||||||
if (this < BigDecimal.ZERO) throw ExpressionException.FactorialCalculation()
|
if (this < BigDecimal.ZERO) throw ExpressionException.FactorialCalculation()
|
||||||
|
|
||||||
println("got $this")
|
|
||||||
|
|
||||||
var expr = this
|
var expr = this
|
||||||
for (i in 1 until this.toInt()) {
|
for (i in 1 until this.toInt()) {
|
||||||
expr *= BigDecimal(i)
|
expr *= BigDecimal(i)
|
||||||
|
@ -34,8 +34,7 @@ fun <T : Throwable?> assertExprFail(
|
|||||||
radianMode: Boolean = true
|
radianMode: Boolean = true
|
||||||
) {
|
) {
|
||||||
Assert.assertThrows(expectedThrowable) {
|
Assert.assertThrows(expectedThrowable) {
|
||||||
val calculated = Expression(expr, radianMode = radianMode).calculate()
|
Expression(expr, radianMode = radianMode).calculate()
|
||||||
println(calculated)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user