RosettaCodeData/Task/Integer-comparison/Kotlin/integer-comparison.kotlin
2016-12-05 22:15:40 +01:00

10 lines
278 B
Text

fun main(args: Array<String>) {
val n1 = readLine()!!.toLong()
val n2 = readLine()!!.toLong()
println(when {
n1 < n2 -> "$n1 is less than $n2"
n1 > n2 -> "$n1 is greater than $n2"
n1 == n2 -> "$n1 is equal to $n2"
else -> ""
})
}