Skip to content

Instantly share code, notes, and snippets.

@anny0739
Created August 23, 2021 15:04
Show Gist options
  • Save anny0739/3025f2931678cf91304828caabd86ee6 to your computer and use it in GitHub Desktop.
Save anny0739/3025f2931678cf91304828caabd86ee6 to your computer and use it in GitHub Desktop.
import kotlin.random.Random.Default.nextInt
fun main(args: Array<String>) {
val trialCount = 5
randomPrint(trialCount)
}
fun randomPrint(trialCount: Int) {
repeat(trialCount) {
println(nextInt())
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment