day1.0 (349B)
- #!/bin/sh
- # SPDX-FileCopyrightText: 2022 Haelwenn (lanodan) Monnier <contact+adventofcode@hacktivis.me>
- # SPDX-License-Identifier: BSD-3-Clause
- # Find the Elf carrying the most Calories. How many total Calories is that Elf carrying?
- awk 'BEGIN { sum = 0 } { if(/^$/){ print sum; sum = 0 } else { sum += $1 } } END { print sum }' | sort -n | tail -1