Sorry I'm in a hospital waiting room just throwing this out quick
Summary for those just joining us:
Advent of Code is an annual Christmas themed coding challenge that runs from December 1st until christmas. Each day the coding problems get progressively harder. We have a leaderboard and pretty good turnout, so feel free to hop in at any time and show your stuff!
Whether you have a single line monstrosity or a beautiful phone book sized stack of OOP code, you can export it in a nice little image for sharing at https://carbon.vercel.app
What did you think about today's problem?
Our Code is 2416137-393b284c (No need to share your profile, you have the option to join anonymously if you don't want us to see your github)
Jump in the discussion.
No email address required.
TRANSB-WORD VICTORY EDITION B-WORD
Jump in the discussion.
No email address required.
Congratulations! Btw, you can install https://github.com/jeroenheijmans/advent-of-code-charts to see all sorts of interesting detailed statistics.
Jump in the discussion.
No email address required.
Jump in the discussion.
No email address required.
I don't think it has much to steal from that page.
Jump in the discussion.
No email address required.
More options
Context
More options
Context
More options
Context
Jump in the discussion.
No email address required.
More options
Context
More options
Context
I'm the last place person to have completed them all, and there are 12 places and 201 points between me and the next person with 100% completion. Comeback story when
Jump in the discussion.
No email address required.
!familyman
Jump in the discussion.
No email address required.
More options
Context
Jump in the discussion.
No email address required.
More options
Context
More options
Context
Python:
Pretty straightforward today. Could be more efficient and cut out a few lines but I'm more happy to have my Saturday back.
That said, I can see this being much more painful for anyone not doing recursion.
Jump in the discussion.
No email address required.
More options
Context
Jump in the discussion.
No email address required.
More options
Context
Too easy, it reminded me of my algorithms exams in uni and school
Jump in the discussion.
No email address required.
It's one of those problems which is only easy if you know how to solve it.
If anything this was more like a tutorial on how to find the next number in a sequence. Expect that to come up again in a later day.
Jump in the discussion.
No email address required.
More options
Context
Yeah, easiest day so far.
Jump in the discussion.
No email address required.
More options
Context
More options
Context
Part2 was really simple today.
Most time was spent on moving from libc++ to libstdc++, because the former doesn't support std::views::slide yet. Which now after looking at cppreference, I could have just used https://en.cppreference.com/w/cpp/ranges/adjacent_transform_view to make it a lot simpler
Jump in the discussion.
No email address required.
More options
Context
Jump in the discussion.
No email address required.
More options
Context
Really fricked this one up, time wise. The one time I'm awake at 5 too .
Jump in the discussion.
No email address required.
My solution is slightly smaller but not as memory-efficient.
Jump in the discussion.
No email address required.
Nice. I looked for diff in the stdlib but was disappointed to find nim's diff is a line diffing algorithm for text.
Jump in the discussion.
No email address required.
Smaller improved version:
This uses a special parameter called a
sink
parameter. From the Nim manual:Jump in the discussion.
No email address required.
More options
Context
More options
Context
More options
Context
@TriHard What you got today?
Jump in the discussion.
No email address required.
More options
Context
More options
Context
I quit last year because it's about low level grunt work and not systems engineering. Deal with it zoomer plebs.
Jump in the discussion.
No email address required.
More options
Context
Is this a hamas reference?
Jump in the discussion.
No email address required.
More options
Context
I wish python had 1-based array indexing
This is my first year doing advent of code, glad I did it. I first learned programming by doing the Project Euler problems so this feels very nostalgic.
Jump in the discussion.
No email address required.
More options
Context
im gay
Jump in the discussion.
No email address required.
That doesn't make you special here
Jump in the discussion.
No email address required.
More options
Context
But I have the smaller peepee
Jump in the discussion.
No email address required.
More options
Context
More options
Context
This one was pretty simple
Jump in the discussion.
No email address required.
More options
Context
Short and sweet
Jump in the discussion.
No email address required.
More options
Context
I was so sure there would be some twist in part 2 to bite me in the butt for going with a recursive solution
Jump in the discussion.
No email address required.
More options
Context
Didn't even have to try for this one, the problem description pretty much guided you through the steps required to solve it
Jump in the discussion.
No email address required.
More options
Context
durrr I have one that doesn't resolve to 0 and I even checked by hand, it resolves all the way down to 2.
Am I missing a step in the instructions or something?
e: and if I don't use abs value for the difference it says I'm wrong
this is rigged
e: posting my beautiful monstrosity in case someone's bored enough to help
e: 1000DC to whoever figures out what my code is doing wrong (this just pt1 btw)
And it fits on the screen :D
Jump in the discussion.
No email address required.
I think one issue might be that your exit condition on the while loop is if the row sums up to 0, that could happen if the entire row is 0, but it can also wrongly happen if some negative values negate the positive values.
Jump in the discussion.
No email address required.
AND THE FINAL ANSWER WAS 5 OFF
lmao enjoy tha coins king
Jump in the discussion.
No email address required.
More options
Context
oh Jesus this gets me at least once a month
every time
Jump in the discussion.
No email address required.
More options
Context
More options
Context
More options
Context
smol bean UwU
Jump in the discussion.
No email address required.
More options
Context
Snapshots:
https://carbon.vercel.app:
ghostarchive.org
archive.org
archive.ph (click to archive)
https://adventofcode.com/2023:
ghostarchive.org
archive.org
archive.ph (click to archive)
Jump in the discussion.
No email address required.
More options
Context