As a parameter to another function:funcName(parameter: (ParameterTypes) -> ReturnType) Note: if the passed-in closure is going to outlive the scope of the method, e.g. if you are saving it to a property, it needs to be annotated with @escaping. As a function parameter:array.sorted(by: { (item1: Int, item2: Int) -> Bool in return item1 < item2 }) As a function parameter with implied types:array.sor