What the difference between using or not using “!” in Swift?
The ! mark is used for the optional value in Swift to extract the wrapped value of it, but the value can be extracted without the ! : var optionalString: String? = "optionalString" println(optionalString) another example using the ! : var optionalString: String? = "optionalString" println(optionalString!) both the codes above get the right value, so I wonder what's the difference between using and not using ! , is it just for detect an error at runtime if the optional value is nil or something else? Thanks in advance. As others have already stated, a really good place to start would be with