Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR ELIXIR

elixir list

iex> [1, "two", 3, :four]
[1, "two", 3, :four]

iex> [1, 2, 3] ++ [4, 5, 6]
[1, 2, 3, 4, 5, 6]

iex> [1, true, 2, false, 3, true] -- [true, false]
[1, 2, 3, true]

iex> [head | tail] = [1, 2, 3]
iex> head
1
iex> tail
[2, 3]
Source by hexdocs.pm #
 
PREVIOUS NEXT
Tagged: #elixir #list
ADD COMMENT
Topic
Name
2+9 =