assignment and expression in a while loop statement kotlin code example
Example 1: while loop kotlin
for (item in collection) print(item)
Example 2: kotlin if
if (a > b) {
max = a
} else {
max = b
}
for (item in collection) print(item)
if (a > b) {
max = a
} else {
max = b
}