List.insert_at/3
defmodule List do
def insert_at(list, index, value)
end
Returns a list with value inserted at the specified index. Note that index is capped at the list length.
Negative indices indicate an offset from the end of the list.
defmodule List do
def insert_at(list, index, value)
end
Returns a list with value inserted at the specified index. Note that index is capped at the list length.
Negative indices indicate an offset from the end of the list.