From: Ummon Date: Mon, 11 Dec 2017 08:38:20 +0000 (+0100) Subject: useless parenthesis X-Git-Url: https://git.euphorik.ch/?a=commitdiff_plain;h=9565edbf4b97adc707be62ccc52ac796b6de179f;p=advent_of_code_2017.git useless parenthesis --- diff --git a/AdventOfCode2017/Day11.fs b/AdventOfCode2017/Day11.fs index df2a86e..9e3629f 100644 --- a/AdventOfCode2017/Day11.fs +++ b/AdventOfCode2017/Day11.fs @@ -8,12 +8,12 @@ let distanceInHex (moves : string) = fun ((x, y, z), furthest) m -> let next = match m with - | "n" -> (x , y + 1, z - 1) - | "ne" -> (x + 1, y , z - 1) - | "se" -> (x + 1, y - 1, z ) - | "s" -> (x , y - 1, z + 1) - | "sw" -> (x - 1, y , z + 1) - | _ -> (x - 1, y + 1, z ) + | "n" -> x , y + 1, z - 1 + | "ne" -> x + 1, y , z - 1 + | "se" -> x + 1, y - 1, z + | "s" -> x , y - 1, z + 1 + | "sw" -> x - 1, y , z + 1 + | _ -> x - 1, y + 1, z next, distance next |> max furthest ) ((0, 0, 0), 0) distance destination, furthest \ No newline at end of file