Logo

Programming-Idioms

  • Scala
  • C#

Idiom #260 Create an empty list of strings

Declare a new list items of string elements, containing zero elements

using System.Collections.Generic;
var items = new List<string>();
using System.Linq;
var items = Enumerable.Empty<string>();
(def items '())

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