solve_day1 :: (test: bool) {
contents := read_entire_file(ifx test then "inputs/day1_test.txt" else "inputs/day1.txt");
sections := split(contents, "\n\n");
elves: [..]u64;
part1: u64 = 0;
for section: sections {
amount: u64 = 0;
lines := split(section, "\n");
for line: lines {
amount += string_to_int(line, 10, u64);
}
part1 = max(part1, amount);
array_add(*elves, amount);
}
quick_sort(elves, (c, b) => cast(s64)b - cast(s64)c);
print("Part 1: %\n", part1);
print("Part 2: %\n", elves[0] + elves[1] + elves[2]);
}