明明簡單的before、after甚至indexOf,swift非要用些看似高大上單詞來編寫函數(shù)方法,作得人難受
2018-03-31
For ; ; ; 在Swift3中這種方式已經(jīng)不能寫了,會提示:C-style for statement has been removed in Swift 3。就是說這種C風格的for循環(huán)已經(jīng)不被支持了,甚至連++這樣的符號也不支持了,所以我們能使用的就是for-in這種方式了
2018-02-16
swift 4 中 這個where 和 , 都不行了。會報錯
error: MyPlayground.playground:28:40: error: top-level statement cannot begin with a closure expression
for case let i in 1...100 , i % 3 == 0 {
^
error: MyPlayground.playground:28:40: error: top-level statement cannot begin with a closure expression
for case let i in 1...100 , i % 3 == 0 {
^
2018-02-12