List comprehensions: Difference between revisions

Content added Content deleted
(Add Swift)
(→‎{{header|Swift}}: Maybe prefix with a statement that the language does not have LCs but the result maybe computed by...)
Line 2,307: Line 2,307:


=={{header|Swift}}==
=={{header|Swift}}==
{{incorrect|Swift|They should be distinct from (nested) for loops and the use of map and filter functions within the syntax of the language.}}


<lang swift>typealias F1 = (Int) -> [(Int, Int, Int)]
<lang swift>typealias F1 = (Int) -> [(Int, Int, Int)]