Skip to content

Instantly share code, notes, and snippets.

@sagarpatel288
Created May 4, 2020 11:13
Show Gist options
  • Save sagarpatel288/618b357b575baea42c86b9ac746e4a8f to your computer and use it in GitHub Desktop.
Save sagarpatel288/618b357b575baea42c86b9ac746e4a8f to your computer and use it in GitHub Desktop.
normal higher order function
fun Int.doSomething(y: Int, ftOne: Int.(Int) -> Int) {
//passing a function type to another function
val funOne = someFunction(ftOne)
/*...*/
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment