2015年6月22日

Swift 通用类型和通用函数 | Generic type and function

摘要: 如果你想交换两个变量的值:1. 整型func swapTwoInts(inout a: Int, inout b: Int) {let temporaryA = aa = bb = temporaryA}2. 字符串func swapTwoStrings(inout a: String, inout... 阅读全文

posted @ 2015-06-22 14:37 小浪鼓 阅读(570) 评论(0) 推荐(0) 编辑

导航