// Code 10 - Random Numbers
// Kotlin Programming
fun rand(start: Int, end: Int): Int {
require(start <= end) { "Illegal Argument" }
return (start..end).random()
}
fun main() {
var start = 1
var end = 20
for (x in 1..10) {
println(rand(start,end))
}
}
To embed this project on your website, copy the following code and paste it into your website's HTML: