What is |> #1960
Locked
formacion-tyris
started this conversation in
General
What is |>
#1960
Replies: 1 comment
-
Hi @formacion-tyris, this is not the correct place to ask this question. Feel free to open a discussion on our "episode code samples" repo: https://github.com/pointfreeco/episode-code-samples/discussions |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
In Episode #13 The Many Faces of Map.
func map<A, B>(_ f: @escaping (A) -> B) -> ([A]) -> [B] {
return { xs in
var result = B
xs.forEach {
result.append(f($0))
}
return result
}
}
I found: [1, 2, 3] |> map(incr)
what is |> ?
why is not a . (dot) ?
is there another symbols combinations like this?
And this? : >>>
[1, 2, 3] |> map(incr) |> map(square)
[1, 2, 3] |> map(incr >>> square)
Thanks
Beta Was this translation helpful? Give feedback.
All reactions