Latest #list Threads Top

Trolleger
I heard that editing a tuple is a much more expensive operation then editing a list i just don’t get the why, when a list is mutated a n...
New
pierrelegall
Problem Currently, List.first/2 and List.last/2 return a default value (or nil) when the list is empty. However, there are cases where an...
New
afhuertass
Hi! I have been dealing with some problem where I have a nested list, I want to keep the nested structure, but if the list is a two elem...
New
user20230119
I want to use get_in(data, keys) for a nested map with some values having a list with maps. map = %{a: 1, aa: [%{b: 2}, %{bb: 22}], aaa:...
New
polovy
I am going through some tutorials, and one of the tasks is to create a list of items by taking first two elements of the existing item an...
New
holasoymas
I’m encountering a strange issue when using Enum.filter/2 in my Elixir script. The problem occurs when I filter a list with a condition t...
New
henry-iteron
In Elixir, I have to use the list of integers and work with that, If my input is [55] it gives the data as ‘7’ but I need it to be [55] ...
New
Oliver
One common problem we face in constructing lists is that there is (AFAIK) no support for conditionally inserting members into list declar...
New
shahryarjb
I have a nested list that should follow a rules to update a record or add a record. I have a keys list which is the path I need to updat...
New
mushu8
Hi, is there a preferred way to keep a list number of items under a certain limit ? In my project there is a GenServer module receiving...
New

This Week's Trending Top

This Month's Trending Top

This Year's Trending Top

pierrelegall
Problem Currently, List.first/2 and List.last/2 return a default value (or nil) when the list is empty. However, there are cases where an...
New
Trolleger
I heard that editing a tuple is a much more expensive operation then editing a list i just don’t get the why, when a list is mutated a n...
New

Last Three Year's Trending Top

mushu8
Hi, is there a preferred way to keep a list number of items under a certain limit ? In my project there is a GenServer module receiving...
New
dongdigua
in python, there is >>> a=[] >>> a.append(a) >>> a [[...]] how to implement this in elixir?
New
polovy
I am going through some tutorials, and one of the tasks is to create a list of items by taking first two elements of the existing item an...
New
Oliver
One common problem we face in constructing lists is that there is (AFAIK) no support for conditionally inserting members into list declar...
New
shahryarjb
I have a nested list that should follow a rules to update a record or add a record. I have a keys list which is the path I need to updat...
New
henry-iteron
In Elixir, I have to use the list of integers and work with that, If my input is [55] it gives the data as ‘7’ but I need it to be [55] ...
New
user20230119
I want to use get_in(data, keys) for a nested map with some values having a list with maps. map = %{a: 1, aa: [%{b: 2}, %{bb: 22}], aaa:...
New
holasoymas
I’m encountering a strange issue when using Enum.filter/2 in my Elixir script. The problem occurs when I filter a list with a condition t...
New
afhuertass
Hi! I have been dealing with some problem where I have a nested list, I want to keep the nested structure, but if the list is a two elem...
New

Trending Over Three Years Top

mathew4509
I have a list say x = ["23gh", "56kh", "97mh"] I would like to pass each element to Val in each iteration. Say, in iteration 1 -------...
New
Ajaxdone
l1 = ["1","2","5","9"] l2 = ["1","9"] List.contains?(l1,l2) Anything like this? to check if l2 is a sublist of l1. I know can use Enum....
New
otuv
Hi, I have a list of maps such as: [%{x: a, y: 1}, %{x: a, y: 1}, %{x: b, y: 0}, %{x: b, y: 1}] From this I would like to find out how...
New
Ninigi
Story skip this if you are not interested in the Why Today I was working on a rewrite of a feature, heavily relying on a 3rd Party HTTP...
New
RazgrizHsu
we can create a list like this list = [ a: 1, b: 2, c: 3 ] but i can’t found api to add element with key to list? list = [] key = :a ...
New
vermaxik
Hello Elixirforum, Could you please explain how List Comparison works in Elixir? Why such list of integers returns true iex(15)> [3...
New
HiroiImanishi
Is there a way to take multiple lists and get all the elements at their n th index and pass them to the function? For example, list1 (= ...
New
josefrichter
I have this list of maps (or structs) and I get a list of newly updated maps. I want to update the maps in the old list with the values f...
New
grangerelixx
I have a list of maps. For example, students = [%{ sid: 1, name: "Bob", score: 80}, %{ sid: 2, name: "Kelly", score: 60},.....] I have...
New
vmg
I’m having trouble trying to zip lists of different lengths because elixir only returns the first match of each list. I have the followi...
New
tushar
The length(List) function can be used in Guards if we want to have different methods based on the length of a list , but can we use the l...
New
benonymus
Hey I am trying to make a very simple shopping site with elixir/phoenix, and I have the items done, but how can I make a shopping cart th...
New
benonymus
Hey I have a list of maps, and those maps are items such: [ %purchase{ amount: #Decimal<2.0>, command: "buy", id: 71, ...
New
shahryarjb
Hi, I have a big list in my GenServer which I want to load them as a pagination, for example I counted it and I have x records and I want...
New
kimc0de
Hi all, I have a .txt file with information like this 11111 0 11112 1 11113 2 11114 3 11115 4 11116 5 11121 6 11122 7 … 66664 z...
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