Method ListToString
- Namespace
- Gamelogic.Extensions.Algorithms
- Assembly
- Gamelogic.Extensions.dll
ListToString<T>(IEnumerable<T>)
Returns a pretty string representation of the given list. The resulting string looks something like [a, b, c].
public static string ListToString<T>(this IEnumerable<T> source)
Parameters
sourceIEnumerable<T>The source to convert to a string. If null, returns the string
"null".
Returns
- string
A string representation of the source.
Type Parameters
TThe type of elements in the source.