Guest User

Untitled

a guest
Jan 22nd, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.17 KB | None | 0 0
  1. extension Equatable {
  2.  
  3. // Usage: 3.isAny(of: 0, 1, 2, 3) // true
  4. func isAny(of candidates: Self...) -> Bool {
  5. return candidates.contains(self)
  6. }
  7.  
  8. }
Add Comment
Please, Sign In to add comment