To repeat a String a few number of times, Kotlin provides us with a Function called 'Repeat()' that repeats a string a few number of times.
Let us see the below example.
fun main() { var x = "Hello" var y = x.repeat(3) println(y) }
So, if you see the output. The statement,
Repeats the String 'Hello' three times.