Last active
July 3, 2018 16:25
-
-
Save PavelGnatyuk/d5215bd19d5894fa1277e2f41d2c9211 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
func goodMorning(morning: Bool, whom: () -> String) { | |
if morning { | |
print("Good morning, \(whom())") | |
} | |
} | |
func giveAname() -> String { | |
print("giveAname() is called") | |
return "Robert" | |
} | |
goodMorning(morning: false, whom: giveAname()) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment