Skip to content

Instantly share code, notes, and snippets.

@rupeshtr78
Last active November 4, 2020 02:13
Show Gist options
  • Save rupeshtr78/313c51e50a418357c3cab8242c5300b3 to your computer and use it in GitHub Desktop.
Save rupeshtr78/313c51e50a418357c3cab8242c5300b3 to your computer and use it in GitHub Desktop.
function1 signature
val function1 = new Function1[Int, Int] {
def apply(x: Int) = x * 100
}
val res = (x: Int) => x * 100
assert(res(10) == function1(10))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment