Swift Trailing Closure

func someFunctionThatTakesAClosure(closure: () -> () ) {

}

Not use trailing closure

someFunctionThatTakesAClosure({

})

Use trailing closure

someFunctionThatTakesAClosure() {

}

Example

let digitNames = [
    0: "Zero", 1: "One", 2: "two", 3: "Three", 4: "Foure",
    5: "Five", 6: "Six", 7: "Seven", 8: "Eight", 9: "Nine"
]

let numbers = [16, 58, 510]
let strings = numbers.map{
    (var number)->String in
    var output = ""
    while number > 0 {
        output = digitNames[number % 10]! + output
        number /= 10
    }
    return output
}
println(strings)

ref: The Swift Programming Language