blob: 94b4cf7c2e76d682635ced7aea096f0777b6af7e (
plain) (
blame)
1
2
3
4
5
6
7
8
9
|
:import std/Math .
:import std/String .
main [answer]
numbers number! <$> (lines 0)
parts split-list-by =?‣ numbers
sums sum <$> parts
answer build (sort-desc sums)
build [^0 : ∑(take (+3) 0)]
|