Introduction to Kotlin
First Kotlin program: printing to the screen using the main function and println.
Simple enough for a 5-year-old to understand
Your first program
A Kotlin program starts from the main function. println prints the text you provide to the screen and moves to the next line.
fun main() { println("Hello!")}Print multiple lines
fun main() { println("First line") println("Second line")}🎯 Exercise & Practice
Test what you've learned — answer, write code, check instantly. (2 left)