Remove last item from the list

Namespace:  EPiServer.BaseLibrary.Collections
Assembly:  EPiServer.BaseLibrary (in EPiServer.BaseLibrary.dll) Version: 5.2.375.236


public virtual TObject RemoveLast()

Return Value

The removed item. If no item existed it returns null.


This operation is an O(n) operation where n is the numer of items in the list. If possible this method should be avoided since all other operations on this class are O(1) operations.

Note that there is no way to distinguish between the case where the list contained an item with the value null versus the case where there was no item to remove. Both cases will return null.

See Also