RosettaCodeData/Task/Function-definition/Kotlin/function-definition.kotlin

8 lines
142 B
Text
Raw Permalink Normal View History

2016-12-05 22:15:40 +01:00
// One-liner
fun multiply(a: Int, b: Int) = a * b
// Proper function definition
fun multiplyProper(a: Int, b: Int): Int {
return a * b
}