Created
April 23, 2020 12:38
-
-
Save sagarpatel288/4dcc7a554d85dc74e4f3ad8cb0d1ea9f to your computer and use it in GitHub Desktop.
Storing an anonymous function in a variable
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
//Storing an anonymous function in a variable | |
val anonymousFunction: (Int, Int): Int = fun(x: Int, y: Int) = x + y |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment