Int 转换为 Double ,Float,CGFloat
let index :Int = 0;
let dou =Double(index);
let f =Float(index)
let cgf =CGFloat(index)
Double转换为Intlet dou =1.222;
let index :Int =Int(dou)
Int 转换为 String
let index :Int = 0;
let str =String(index);
Double转换为String let dou = 1.222;
let str = String(dou);
String转换为Int
let str ="22"
let index =Int(str);