That sounds awesome, thanks for the suggestion!
Reminds me of this gem: https://lizengland.com/blog/2014/04/the-door-problem/
Had that issue too, search in Start for “Default Apps”, then scroll to the bottom and click “Choose default application by file type”. Then scroll to .pdf
and choose Sumatra. The settings window may crash for some reason, but for me the file association did seem to stick after that.
Heavy stuff first, cold things together, fragile stuff last.
Try Bricklink, I’ve purchased “old” sets there for a decent price. Be sure to check the seller’s rating/reviews
I optimized Part1 by directly referencing workflows between each rule (instead of doing a table lookup between them), in expectation of part 2 needing increased performance. But that turned out to not be needed 😋
I had to dig through my dusty statistics knowledge for part 2, and decided to try out Mermaid.js to create a little graph of the sample input to help visualize the solution.
After that it was pretty straightforward.
Thank you too, I’ll pass on your compliments to Mochi 😻
This is your life now
This was actually something I learned for my job, it was nice to be able to apply it here.
I like your commitment to wheel-reinvention, it can be a lot more fun than going for an existing or ‘intended’ approach.
Good job on persevering with this one. Your approach for part 2 sounds quite viable, it is very similar to the Ear clipping method for triangulating a polygon.
Decided to go for a polygon approach for part 1 using the Shoelace formula to calculate the area. This meant part 2 only resulted in larger values, no additional computation.
Code runs in <1ms for part 1 and 2 combined
python-level intuitive-to-read language with static typing
Agreed, this is exactly Nim
Fork is great!
Yeah the descriptions contain a lot of story fluff, but also critical bits of information.
Happy I decided to not actually expand anything. Manhattan distance and counting the number of empty rows and columns was plenty. Also made part 2 an added oneliner :) It’s still pretty inefficient iterating over the grid multiple times to gather the galaxies and empty rows, runtime is about 17ms
I could also extract and re-use my 2D Coord and Grid classes from day 10, and learned more about Nim in the process ^^
Yepp, this one got me as well! I found the discrepancy when testing against the sample through, which showed the result for a factor 100 (which needed to be 99). Knowing the correct outcome made debugging a lot easier.
I always make sure my solution passes all the samples before trying the full input.
I use OneCalendar, it works with a lot of email/calendar hosts, looks good, and is very responsive.
Alternatively, Thunderbird has a calendar feature built-in.
(Edit) failed to see which community this was, OneCalendar is sadly not open source.