swift 2.0
字符串裁剪:
let text = "1234567890" let t = text.startIndex.advancedBy(1)
text = text.substringFromIndex(t)//"234567890"
let t1 = text.endIndex.advancedBy(-1)
text = text.substringFromIndex(t)//"123456789"
Int To String:
let t = 12
let s = t.description//s="12"
String To Int
let s = "12"
let t = Int(s)//t=12
参考:
http://www.swiftmi.com/topic/76.html