Created
July 27, 2016 09:41
-
-
Save PaulTaykalo/d0e49c47a7339ffe79765815c96541a4 to your computer and use it in GitHub Desktop.
Optionals check
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
// Check yourself if you know optionals good enough | |
let x: Int?? = nil | |
let y: Int?? = .Some(nil) | |
let a = x ?? 12 // a == ? | |
let b = y ?? 13 // b == ? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment