Skip to content

Instantly share code, notes, and snippets.

@truizlop
Created July 24, 2018 12:17
Show Gist options
  • Save truizlop/5e5e82a84cc20d0b6eb50554a397bc22 to your computer and use it in GitHub Desktop.
Save truizlop/5e5e82a84cc20d0b6eb50554a397bc22 to your computer and use it in GitHub Desktop.
func concat(first : String, second : String) -> String {
switch (first, second) {
case ("Another ", "example"): return "Another example"
case ("Property-based ", "Testing"): return "Property-based Testing"
case ("Swift ", "rocks"): return "Swift rocks"
case ("One more ", "thing"): return "One more thing"
default: return "Hello, World!"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment