Forum menu
Day 15 still and a wee optimisation tweak - I was pre-working out and caching some information that I didn't need. So 6ms for part 1 and 2.3s for part 2. That'll do at the moment. I've got a free evening to have a look at Day 16 tonight.
Still "brute-force" but it's just brute forcing a very quick operation. 🙂
Another hard one today
yeah I found round 1 easy enough - few bugs but the logic was ok. Took me ages to wrap my head around part 2 - algo ran for 15 mins in the end, so I expect I missed something 😀
I found part 1 pretty hard. My solution for part 2 runs in just over a minute, but I'm really not proud of it.
Just seen this. Will try and play catch up, although my powershell skills are even rustier than last year and I didn't do so well then.
That was ok-ish. Done now and part 2 solves in just under a second. It's not pretty though.
I'm sure there's a better A* way to do it though that is a few milliseconds.
I'm pretty impressed with the proportion of active people to getting solutions on here - I'm in actual programming groups who don't have as good a ratio.
found today fairly straight forwards - just a case of chunking through. Still tried to brute force part 2 which is never the right answer 😀
21ms and 310ms respectively
and todays is even easier than yesterdays. sub hour for me!
Finally got round to completing day 1. Don't think I'll be topping any leader boards.
Had part 1 in about 5 minutes today, flailed a lot with part 2, but got there in the end.
Up to date again. I didn't really enjoy 17 - silly mistake and then an ugly solution:
The second part, I was lucky. Lots of visualisation for debugging part 1 then checked what the status was when I was looping the wind to the start of the file and found the picture looked the same. Then an ugly "it gains this many rows for the loop over wind" - different number for the first loop and then the last couple of hundred steps. Dumped the numbers into Excel and worked out total.
Day 18 was fun. Liked that.
euain - yeah, I had a silly bug where I'd changed which direction I considered to be up halfway through, and didn't catch all the places.
Part 2 I got more through luck than being clever, I think. It actually fails on the example!
Today's is properly wtf.
yesterdays took me ages. the thing that got the performance managable (it never finished before) was
today is much easier!
I had a really annoying off by one error that took me ages to find today, but otherwise okay.
Robots was a hard one for me - spent far too long messing about with that.
Todays was a lot easier though I had to scratch my head to get one case that seems a bit inconsistent.
I'm glad I'm not the only person who flailed a bit today
I went straight for a doubly linked list, had off by one errors for when it was moving over itself.
Took me *ages* to find. And, for the first time, I ended up debugging against someone else's solution.
Todays was very nice, I thought.
No complex rules and ended up solving the problem properly (60ms running time, including parsing the file) while my computer was still trying to brute-force the solution (stopped after 2h I could see it was still miles off).
Yeah, plain sailing today.
The only thing was thinking it'd be quicker to solve the last bit by hand rather than writing code.
Spoiler: It was not.
Solved today in the same way I was taught years ago
really easy today I found. just a case of chunking through the problem space. I almost assumed my initial approach (brute force) for part 2 wouldn't work but it was fine!
Just a lot of fiddly code yesterday, didn't enjoy it.
Today's was nice and straight forward, though.
Yesterday's ended up involving drawing shapes on paper and cutting it out. I was convinced I'd find some way of programatically defining the transitions over the edges but ended up just hard-coding the 14 different transitions of my input. Pleased when it worked but not really fun.
Todays was easy enough. I suspect there might be something clever way to do it but my laptop churned through my naive code (with some hideous inefficiencies that I kept thinking "I'll come back and sort in part 2 when I need it to be faster") in less than half a second. I'll leave it there and get on with some proper work.
Part 2 was trivial in mine - I just changed my for loop to execute for ever and added a "if (proposedMoves.isEmpty()){break;}" statement instead.
I'm still waiting for something to cause the levels of pain that the scanners/beacons did last time. That hurt my brain.
Yesterday’s ended up involving drawing shapes on paper and cutting it out.
Yeah, I ended up writing numbers on the sides of a puzzle book (hacked most of it together on a plane, that's what I had a available) to work out the relationships.

State-of-the-art here... I even drew the shape in Omnigraffle to cut out.
yeah I also had a cut out cube 🙂
today was quite simple after all the practice
Yup - simple enough today. Quite a relief that I could just add an outer loop to handle part 2. That was unexpectedly easy.
I was getting ready to have to store a big cache of states and positions - I think the states repeat every width x height minutes but both solutions run in <1s so I settled for my simple implementation.
Who's helping the elves out this year?
Nice easy start this year - though I'm being lazy and sticking to my comfy place in Java. Every year I think I'll try to learn something new (Rust, Python,...) but never have the time.
Yes, I'm in again. Sticking with Go - I'd like to try a new language, but it's not even like I get to spend much time in the languages I do know lately!
Perhaps this will be a good way to see how Chat GPT generates code?
Perhaps this will be a good way to see how Chat GPT generates code?
That was so last year :p
Another year, another AoC adventure.
How's it going this year? So far, a nice gentle easing back into the way of it. Today is an exercise in "read the rules" as I jumped in before I'd read them all.. a couple of wrong answers before I went back and actually read them.. ah, we need to all be in the same direction.. etc.
I suspect it won't be long before it won't be doable over a cup of coffee before work. (By me anyway).
I just read today's. I've not started yet, but it's one of my favourite types of Advent of Code problem. Yay.
Agreed, I enjoy this kind of problem. I've got part 1 done but work is getting in the way and I'll not get a chance to play on part 2 until later tonight. Very nerdy, but I'm looking forward to getting stuck in. A couple of ideas how I might do it..
There is a STW AoC leaderboard if you're interested - or maybe you're on it. (I'm not sure who set it up - I think I joined a couple of years ago). If you want, PM me and I'll try to work out what's needed to join it.
It's back on page 2 - posted by @haloric - leaderboard code is: 502307-275d7a99
I got a notification !.
I don't use STW any more - feel free to start a new leaderboard or use the existing one to your hearts content.
cheers.
Always fancied trying this and actually giving it a go this year. A bit late but started a bit last night and halfway through day 2 so far... so far so easy, I assume it gets a lot harder!
Anyway it should be a fun challenge, let's see if I can manage it. Only really posting here for motivation so I actually do it and don't procrastinate into oblivion :-p
Anyone partake this year. Only 12 puzzles this time. Most were OK.
Day 10 part 2 was a challenge - ended up taking 3h45 to solve on my laptop. That was after optimising as it had run overnight and only got 10 of the 195 lines solved. Got the answer though. 🙂
I had my university textbooks ready for a the proper solution but read the subreddit for some hints and ended up with an algorithm that got the answer in a second. I learned something.
Other than that, all good fun and 24 stars earned 🙂