Created
December 28, 2013 10:58
-
-
Save aruld/8158266 to your computer and use it in GitHub Desktop.
Kotlin Functional processing http://aruld.info/why-java-8-will-be-a-top-contender-for-java-next-languages/
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
fun main(args: Array<String>) { | |
val employees = array("neal", "s", "stu", "j", "rich", "bob") | |
val result = employees filter { it.length > 1 } map { it.capitalize() } reduce { x, y -> x + "," + y } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment