Created
October 29, 2018 21:17
-
-
Save teivah/6171bed18b32b96b579e6c7f73e6b6f5 to your computer and use it in GitHub Desktop.
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
def foo(i: Int, f: Int => Int): Int = { | |
f(i) | |
} | |
def bar() = { | |
val increment: Int => Int = (x: Int) => x + 1 | |
val n = foo(5, increment) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment