From 520a01ed88fafb165ecb3eaa9fd3e39db0431722 Mon Sep 17 00:00:00 2001 From: Tomasz Chojnacki Date: Sat, 10 Dec 2022 13:26:15 +0100 Subject: Finish day 10 --- aoc-2022-dotnet/Common/Util.fs | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'aoc-2022-dotnet/Common/Util.fs') diff --git a/aoc-2022-dotnet/Common/Util.fs b/aoc-2022-dotnet/Common/Util.fs index a9f3a1e..6393aad 100644 --- a/aoc-2022-dotnet/Common/Util.fs +++ b/aoc-2022-dotnet/Common/Util.fs @@ -25,6 +25,11 @@ module Util = | [ x; y ] -> x, y | _ -> failwith "Invalid string format!" + let matrixToString m = + m + |> Seq.map (Seq.map string >> String.concat "") + |> String.concat "\n" + let topN n xs = let rec insertSorted x = function -- cgit v1.2.3