Skip to content

Instantly share code, notes, and snippets.

@dineshba
Created May 21, 2018 18:58
Show Gist options
  • Save dineshba/d53a7c9877728df2598ccf417ac4bbe1 to your computer and use it in GitHub Desktop.
Save dineshba/d53a7c9877728df2598ccf417ac4bbe1 to your computer and use it in GitHub Desktop.
struct Cherry: Eatable {
var taste: Taste = Taste.sweet
func isBitter() -> Bool {
return self.taste == .bitter
}
}
let 🍒 = Cherry() // literally we can have variable name like this🤓
struct Chilly: Eatable {
var taste: Taste = Taste.spicy
func isBitter() -> Bool {
return self.taste == .bitter
}
}
let 🌶 = Chilly()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment