This commit is contained in:
bluepython508
2024-12-03 11:16:12 +00:00
parent b24b64a22c
commit ec51a3b67a
6 changed files with 41 additions and 1 deletions

View File

@@ -1,10 +1,14 @@
role AOC {
# Exists mostly to allow day3 to run a subparse instead of a full parse
method aocparse(::?CLASS:U: $content) {
self.parse($content).made
}
method part1(::?CLASS:U: $v) { ... }
method part2(::?CLASS:U: $v) { ... }
method main(::?CLASS:U:) {
my \parsed = self.parse(slurp(@*ARGS[0])).made;
my \parsed = self.aocparse(slurp(@*ARGS[0]));
say self.part1(parsed);
say self.part2(parsed);
}