This code snippet compiles without error, but never prints the results when executed. What could be wrong?kotlinval result = generateSequence(1) { it + 1 }.toList()println(result)

🎲 Try a Random Question  |  Total Questions in Quiz: 83  |  🧠 Study this quiz with Flashcards
This question is part of a full practice quiz:
Kotlin Quiz — practice the complete quiz, review flashcards, or try a random question.

Kotlin MCQs For LinkedIn Skill Assessments.


This code snippet compiles without error, but never prints the results when executed. What could be wrong?<br>kotlin<br>val result = generateSequence(1) { it + 1 }.toList()<br>println(result)<br>