Swift💯 1liner; FP+Swift Algorithms; no curly braces
One-Liner, expanded and annotated (accepted answer)
**One-Liner, expanded and annotated (accepted answer)**
```
class Solution {
    func sumOfGoodNumbers(_ nums: [Int], _ k: Int) -> Int {
        zip(nums, 
            zip(
                chain([0].cycled(times:k), nums), // nums[i] - k
                chain(nums[k...], [0].cycled())   // nums[i] + k
            )
            .map(max)
        )
        .filter(>) // filter nums[i] +/- k 
        .map(\.0)  // extract filtered nums[i] from tuple
        .reduce(0,+) // sum filtered numbers
    }
}
```
['Swift']