Created
July 18, 2019 17:30
-
-
Save parzibyte/3b7d63df1fa106126b0f790eaeecb5e8 to your computer and use it in GitHub Desktop.
Función suma en Kotlin https://parzibyte.me/blog
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Definir la función | |
fun sumar(numero1: Int, numero2: Int): Int { | |
return numero1 + numero2 | |
} | |
// Invocarla | |
val resultado = sumar(20, 1) | |
println("La suma es: $resultado") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment