From a11f4f9e878a7abfafb73b72248ecbd3098aebd6 Mon Sep 17 00:00:00 2001 From: talksik Date: Sun, 18 Jun 2023 22:00:50 -0700 Subject: [PATCH] comment --- src/main.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main.rs b/src/main.rs index 59c4969..56e0e42 100644 --- a/src/main.rs +++ b/src/main.rs @@ -41,6 +41,7 @@ fn get_sum_priorities_errors(rucksacks: Vec) -> u32 { // we have found the error let priority = item.get_priority(); total_priority_errors += priority; + // break out so that we don't double count the error if it appears twice break; } }