Print all elements

Report a typo

Choose the correct ways to print all the elements of the numbers list.

a)

for (element in numbers) {
    println(element)
}

b)

for (i in numbers.indices) {
    println(i)
}

c)

for (i in 1..numbers.size) {
    println(numbers[i])
}

d)

for (i in numbers.indices) {
    println(numbers[i]) 
}
Select one or more options from the list
___

Create a free account to access the full topic