Skip to content

Instantly share code, notes, and snippets.

@delabassee
Created July 23, 2018 11:22
Show Gist options
  • Save delabassee/2b571789392b8cb89dbf5ce7b444b274 to your computer and use it in GitHub Desktop.
Save delabassee/2b571789392b8cb89dbf5ce7b444b274 to your computer and use it in GitHub Desktop.
package com.fn.example
fun hello(input: String) = when {
input.isEmpty() -> ("Hello, world!")
else -> ("Hello, ${input}")
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment