3 ms·
I'd like to share some solutions. This is a compact notation for Elixir using the capture operator `&` and importing all Enum functions: import Enum [1,2,
by ontofractal 10y ago
I'd like to share some solutions. This is a compact notation for Elixir using the capture operator `&` and importing all Enum functions:
import Enum
[1,2,3,4] \
|> filter(& rem(&1,2) == 0 ) \
|> map(& &1*&1) \
|> reduce(0, & &1 + &2)
Also ExActor (https://github.com/sasa1977/exactor https://github.com/sasa1977/exactor) library does exactly what you want: generates "standard double" GenServer functions and significantly reduces GenServer boilerplate.
I've discovered that it's significantly easier for me to get in the flow state of mind while programming in Elixir. Comfortable and powerful. Definitely a worthwhile investment of time and effort.