From 171be3c3bb67a97f0d53d297c0ada851fe684c04 Mon Sep 17 00:00:00 2001 From: Wouter Groeneveld Date: Wed, 21 Mar 2018 17:19:24 +0100 Subject: [PATCH] listExt name --- sorting/dotnet/Sorting/ListExt.cs | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 sorting/dotnet/Sorting/ListExt.cs diff --git a/sorting/dotnet/Sorting/ListExt.cs b/sorting/dotnet/Sorting/ListExt.cs new file mode 100644 index 0000000..79eafa3 --- /dev/null +++ b/sorting/dotnet/Sorting/ListExt.cs @@ -0,0 +1,13 @@ +using System.Collections.Generic; +using System.Linq; + +namespace Sorting +{ + public static class ListExt + { + public static string AsString(this List list) + { + return "(" + string.Join(", ", list.Select(x => x.ToString())) + ")"; + } + } +} \ No newline at end of file