diff options
author | June McEnroe <june@causal.agency> | 2018-12-02 00:49:25 -0500 |
---|---|---|
committer | June McEnroe <june@causal.agency> | 2018-12-02 00:49:25 -0500 |
commit | 554747afc40e410aabfe04ea8649dd086a0bf298 (patch) | |
tree | 299f9569665e32816666fdd700f32a01a6a6525c | |
parent | Solve day 2 part 2 (diff) | |
download | aoc-554747afc40e410aabfe04ea8649dd086a0bf298.tar.gz aoc-554747afc40e410aabfe04ea8649dd086a0bf298.zip |
Un-hardcode width of input in day 2
-rw-r--r-- | 2018/day02-2.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/2018/day02-2.sh b/2018/day02-2.sh index c7876cb..ef8bcc2 100644 --- a/2018/day02-2.sh +++ b/2018/day02-2.sh @@ -1,6 +1,6 @@ input=$(mktemp) cat > $input -for i in $(seq 26); do +for i in $(seq $(head -n 1 $input | wc -c)); do colrm $i $i < $input | sort | uniq -d done rm $input |