 | RankedMapTKey, TValueKeyCollectionGetDistinctCount Method |
Returns the number of distinct keys in the map.
Namespace:
Kaos.Collections
Assembly:
KaosCollections (in KaosCollections.dll) Version: 4.2.0.0
Syntaxpublic int GetDistinctCount()
Return Value
Type:
Int32The number of distinct keys in the map.
Remarks
This is a O(
m log
n) operation
where
m is the distinct key count
and
n is
Count.
Examples
The below snippet is part of a larger example of the
RankedMapTKey, TValueclass.
Console.WriteLine ($"\nDistinct format count: {fmt.Keys.GetDistinctCount()}");
Console.WriteLine ($"Total format count: {fmt.Count}");
See Also