aoc2021/d01/d01_1.awk

16 lines
73 B
Awk

NR == 1 {
A = $1
next
}
$1 > A {
N++
}
{
A = $1
}
END {
print N
}