Logo

Programming-Idioms

  • Caml
  • Ruby

Idiom #291 Remove sublist

Delete all the elements from index i (included) to index j (excluded) from the list items.

items.slice!(i...j)
items.removeRange(i, j);

New implementation...
< >
programming-idioms.org