Guest User

Untitled

a guest
Jun 23rd, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. fun doSomething() {
  2. ...
  3. doComplexTask("Akexorcist", { name ->
  4. "Mr.${name.trim()}"
  5. }, { fullName ->
  6. System.out.println("Hello, $fullName")
  7. })
  8. }
  9. fun doComplexTask(name: String,
  10. method1: (name: String) -> String,
  11. method2: (fullName: String) -> Unit) {
  12. doSomething1(name)
  13. method1(name)
  14. doSomething2(name)
  15. method2(name)
  16. doSomething3(name)
  17. }
Add Comment
Please, Sign In to add comment