Latest #list-comprehension Threads Top

W3NDO
I was using a for loop while matching on a pattern something like this for {a,b, _} <- my_list do ... end And I noticed that this wa...
New
kimc0de
Hi all, I’m trying to do some Leetcode exercises in elixir. I have a function that takes an integer and it needs to return a list of lis...
New
Sebb
there is this exercism exercise: Given an input integer N, find all Pythagorean triplets for which a + b + c = N. For example, with N ...
New
Sebb
I understand these results: iex(1)> for <<b::1 <- <<0xff::16>> >>, do: b [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1,...
New
blackened
I am a complete Elixir beginner. I am trying to understand certain concepts with the following Mastermind sub-problem. Suppose I have tw...
New
pillaiindu
These two work: iex(1)> for {key, val} <- %{"a" => 1, "b" => 2}, do: {key, val * val} [{"a", 1}, {"b", 4}] iex(2)> for {...
New
Fl4m3Ph03n1x
Background I have some code that uses list comprehensions in elixir and performs some long operations. I need this code to be lazily eval...
New
Fl4m3Ph03n1x
Background For the longest time I have been estranged to the magic lands of comprehensions in FP languages. Now I am trying to pick it u...
New
david234
I have this list which has order and order_details. I want to update the quantity field inside order details by subtracting it with the q...
New
Sebb
I can do: if true, do: :foo, else: :bar and: if true do :foo else :bar end And I can do: for i <- 0..3, do: {i, i+i}, into: %...
New

This Week's Trending Top

This Month's Trending Top

This Year's Trending Top

W3NDO
I was using a for loop while matching on a pattern something like this for {a,b, _} <- my_list do ... end And I noticed that this wa...
New

Last Three Year's Trending Top

Trending Over Three Years Top

holder66
Coming from Python and its version of list comprehensions, I am looking for a way to accomplish in Elixir, transposition of a list of li...
New
Fl4m3Ph03n1x
Background I have some code that uses list comprehensions in elixir and performs some long operations. I need this code to be lazily eval...
New
CharlesO
Say we have a simple list comprehensions: for x <- [some_list] do case _compute(x) do nil -> nil # directly exclude this val...
New
vishal-h
How would you write the accepted answer of https://stackoverflow.com/questions/19293481/how-to-elegantly-interleave-two-lists-of-uneven-l...
New
Fl4m3Ph03n1x
Background For the longest time I have been estranged to the magic lands of comprehensions in FP languages. Now I am trying to pick it u...
New
kimc0de
Hi all, I’m trying to do some Leetcode exercises in elixir. I have a function that takes an integer and it needs to return a list of lis...
New
Sebb
I can do: if true, do: :foo, else: :bar and: if true do :foo else :bar end And I can do: for i <- 0..3, do: {i, i+i}, into: %...
New
david234
I have this list which has order and order_details. I want to update the quantity field inside order details by subtracting it with the q...
New
david234
This is from my arbitrage project. I need to find the best probability of where the client can buy and where he can sell to get maximum p...
New
pillaiindu
These two work: iex(1)> for {key, val} <- %{"a" => 1, "b" => 2}, do: {key, val * val} [{"a", 1}, {"b", 4}] iex(2)> for {...
New
blackened
I am a complete Elixir beginner. I am trying to understand certain concepts with the following Mastermind sub-problem. Suppose I have tw...
New
Sebb
there is this exercism exercise: Given an input integer N, find all Pythagorean triplets for which a + b + c = N. For example, with N ...
New
Sebb
I understand these results: iex(1)> for <<b::1 <- <<0xff::16>> >>, do: b [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1,...
New
  • Follow
  • Join
  • Shape
the conversation

Latest on Elixir Forum

Elixir Forum

Similar Portals

    None added yet

We're in Beta

About us Mission Statement