01 2016 档案

Swift Tips笔记
摘要:“??”操作符可以判断输入并在当左侧的值是非 nil 的 Optional 值时返回其 value,当左侧是 nil 时返回右侧的值.例:var level: Int?var startLevel = 1var currentLevel = level ?? startLevel//currentL... 阅读全文

posted @ 2016-01-04 15:59 bibibi_liuliu 阅读(256) 评论(0) 推荐(0)