From 1f6867dc98d99ff982852b3d1bd9b4ce37af9a6f Mon Sep 17 00:00:00 2001 From: Matej Focko Date: Mon, 6 Dec 2021 10:34:59 +0100 Subject: [PATCH] day(05): switch to constant Signed-off-by: Matej Focko --- src/day05/Day05.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/day05/Day05.kt b/src/day05/Day05.kt index fa6f46e..f792482 100644 --- a/src/day05/Day05.kt +++ b/src/day05/Day05.kt @@ -48,7 +48,7 @@ fun readVector(input: String): Vector { } fun findOverlaps(input: List): Int { - var points: MutableMap = mutableMapOf() + val points: MutableMap = mutableMapOf() input .flatMap { it.points } .forEach { points[it] = 1 + points.getOrDefault(it, 0) }