io.data2viz.random.irwinHall.kt Maven / Gradle / Ivy
package io.data2viz.random
fun randomIrwinHall(n: Number = 1): () -> Double = {
var sum = 0.0
(0 until n.toInt()).forEach {
sum += random()
}
sum
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy