```
class Solution {
func twoSum(_ nums: [Int], _ target: Int) -> [Int] {
for index in 0..<nums.count {
let i = index + 1
for index2 in i..<nums.count {
var sum = nums[index] + nums[index2]
if sum == target {
return [index ,index2 ]
}
}
}
return [0,0]
}
}
```