Kotlin - Loops and Ranges
Identify the error in this Kotlin code snippet:
val fruits = listOf("apple", "banana", "cherry")
for fruit in fruits {
println(fruit)
}