From c8b11e72b64719ed0530f1c0fa7cb7c5bbf8a877 Mon Sep 17 00:00:00 2001 From: Greg Burri Date: Wed, 2 Dec 2020 10:04:01 +0100 Subject: [PATCH] Simplify a bit the sum (to sum boolean with integer is possible) --- main.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.jl b/main.jl index 0c257ac..dd5e7f5 100644 --- a/main.jl +++ b/main.jl @@ -284,7 +284,7 @@ function nb_of_valid_passwords_part1(passwords :: AbstractArray{Password}) for c in password.p m += c == password.policy_char end - if m ∈ password.policy_range 1 else 0 end + m ∈ password.policy_range end, passwords ) -- 2.45.2