StringHelper MatchCardinality Method CleanCode C# Libraries v1.2.03 API
Matches the cardinality of the element to the value to yield, for example "1 elephant" or "2 elephants".

Namespace: CleanCode.Data
Assembly: CleanCode (in CleanCode.dll) Version: 1.2.3.0 (1.2.03)
Syntax

public static string MatchCardinality(
	int value,
	string element
)

Return Value

value + space + element + "s" as warranted
Remarks

Note that this does not take into account "es" vs. "s".
See Also