我有Int这样的
Int
let num: Int = 123
现在我想将它分成数字,1, 2, 3然后将它们相加以获得6.
1, 2, 3
6
你能帮助我吗?
arrays integer swift
arrays ×1
integer ×1
swift ×1