diff options
author | Thomas Voss <mail@thomasvoss.com> | 2024-12-01 20:01:11 +0100 |
---|---|---|
committer | Thomas Voss <mail@thomasvoss.com> | 2024-12-01 20:01:11 +0100 |
commit | 425c822826314a31f26cee06b9ac2520351c8829 (patch) | |
tree | da6e386581bf5d39a1d65a3514abfa07afd19fbe /2024/01/puzzle-2.awk | |
parent | ad158f445be1e7f85b887037913996b165cbebe0 (diff) |
Make use of NR
Diffstat (limited to '2024/01/puzzle-2.awk')
-rwxr-xr-x | 2024/01/puzzle-2.awk | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/2024/01/puzzle-2.awk b/2024/01/puzzle-2.awk index 8400a16..75ab83a 100755 --- a/2024/01/puzzle-2.awk +++ b/2024/01/puzzle-2.awk @@ -1,7 +1,7 @@ #!/usr/bin/awk -f { - xs[++i] = $1 + xs[NR] = $1 ys[$2]++ } |