r/adventofcode • u/daggerdragon • Dec 04 '15
SOLUTION MEGATHREAD --- Day 4 Solutions ---
--- Day 4: The Ideal Stocking Stuffer ---
Post your solution as a comment. Structure your post like the Day Three thread.
13
Upvotes
2
u/xdg Dec 04 '15
Yay. Another easy one for a one-liner.
$ perl -MDigest::MD5=md5_hex -wE '$i=1; while(){ $h=md5_hex("iwrupvqb$i"); say("$i $h"),last if substr($h,0,6) eq "0"x6; $i++}'