Logo

Programming-Idioms

History of Idiom 117 > diff from v45 to v46

Edit summary for version 46 by silver-dragon:
New VB implementation by user [silver-dragon]

Version 45

2019-09-26, 22:16:39

Version 46

2019-09-30, 14:22:16

Idiom #117 Get list size

Set n to the number of elements of list x.

Illustration

Idiom #117 Get list size

Set n to the number of elements of list x.

Illustration
Extra Keywords
length
Extra Keywords
length
Code
Dim ItemList As New List(Of String)(New String() {"one", "two", "three"})
Console.WriteLine(ItemList.Count)
Doc URL
https://docs.microsoft.com/en-us/dotnet/api/system.collections.generic.list-1?redirectedfrom=MSDN&view=netframework-4.8