// Code 4 - If in a for loop
// Pure Kotlin

fun main() {
    for (x in 1..5) {
        if (x < 3) {
            println("Bad!")
        }
        else if (x == 3) {
            println("OK!")
        }
        else {
            println ("Good!")
        }
    }
}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: