adventofcode/2023/02/Part2.pm
2023-12-02 13:33:33 -05:00

17 lines
236 B
Perl

use 5.38.0;
package Part2;
use Part1;
use List::AllUtils qw/ min product sum /;
sub solution_2 ($input) {
sum
map { product $_->@{qw/ red blue green /} }
map { Part1::parse_line($_) }
split "\n", $input;
}
1;