Live data from Hacker News

Advent of Code 2024

adventofcode.com

431–440 of 580 posts

Re: Advent of Code 2024

#431

I love AoC! Did it the last 2-3 years in Rust, hanging out in a discord where we all try to make the absolute fastest solutions. Learnt all kinds of crazy performance hacks and some advanced algorithms & SIMD that way. This time I'm trying to do them in Rust and Golang in an effort to either learn to like/tolerate Golang (because we use it at work) or prove my hypothesis that it sucks and never use it unless I have t…

'd you be interested in sharing the discord? :) I try every year to optimize for speed in zig: https://github.com/ManDeJan/advent-of-code

This server seems to be active, although they are all unofficial servers from enthusiasts.

https://discord.gg/wYmyYsf

Re: Advent of Code 2024

#432
post #418
post #173

Earlier quoted context omitted.

enshittification isn't "things become worse" - it's the specific process of how services worsen in 3 stages: > Here is how platforms die: first, they are good to their users; then they abuse their users to make things better for their business customers; finally, they abuse those business customers to claw back all the value for themselves. Then, they die. I call this enshittification, and it is a seemingly inevitabl…

Just because that's how it was defined in a blog post doesn't mean that it's the only way to use it

We already have plenty of words for the ancient and generic concept of things-getting-worse, like "ruining".

Re: Advent of Code 2024

#433
post #84

Earlier quoted context omitted.

The global leaderboard is so fast that any AI assistance would literally slow them down, here's one of the guys who tends to score highly solving today's puzzle. ( https://youtu.be/ym1ae-vBy6g ), and on the more complicated days that's even more pronounced because anyone who is even somewhat decent doesn't need to ask chatgpt how to write Dijkstra. Obviously if you're doing it recreationally you can cheat with AI but…

The "winner" solved it in 9 seconds using AI so I don't understand how you can claim that. https://adventofcode.com/2024/leaderboard/day/1

I'm curious to know how did you know the winner used AI?

Re: Advent of Code 2024

#434
post #386

Earlier quoted context omitted.

Oh yeah, me neither. The competition is far too intense. What takes me hours takes the competitors minutes.

I actually made somewhat of an effort this time, made sure I was awake in good coding shape when the problem was released. Had a scaffold set up for running the code based on previous years. And I'm a pretty decent all-round coder, should be by now. Ended up at around spot 6500. Boggles my mind to even imagine what it would take.

You can see videos of what it takes; Jonathan Paulson makes the leaderboard often with Python and puts videos of him doing it on YouTube; he made positions 25 and 40 on day 1 this year and here is his video: https://www.youtube.com/watch?v=ym1ae-vBy6g

Re: Advent of Code 2024

#435

Earlier quoted context omitted.

It's best for me when I do something that I ordinarily don't do for AoC. I find no particular pleasure in using an everyday language like Python for it, because as you said it's too easy. I have used Haskell, Racket, and in some easier cases APL and it's been fun. Treating it more like a puzzle than an actual programming assignment. When learning new languages, it's best to do something that actually makes you think…

C# allows for terser and very functional-y implementations thanks to differences between LINQ and Java’s Streams.

I guess, but it's not really a fundamentally different programming paradigm, which is what I was getting at.

Re: Advent of Code 2024

#436

Earlier quoted context omitted.

It's best for me when I do something that I ordinarily don't do for AoC. I find no particular pleasure in using an everyday language like Python for it, because as you said it's too easy. I have used Haskell, Racket, and in some easier cases APL and it's been fun. Treating it more like a puzzle than an actual programming assignment. When learning new languages, it's best to do something that actually makes you think…

It goes into "too bothersome" territory in this case for me. Competing in a local leaderboard was fun and kept me engaged until the end, but it was only possible by choosing a comfortable language to be free to actually think about the puzzle itself to solve it fast. Choosing something that I'm not already familiar with (or that isn't well-suited for this type of tasks) is a great way to ramp up the difficulty and pe…

> There's plenty of actually useful projects I could do in this time to learn new things instead after all.

I suppose. I do actually useful projects at work. AoC reminds me of why I personally loved programming in the first place - solving small technical puzzles. I don't like trying to make every single moment of my life "productive".

Re: Advent of Code 2024

#437

Earlier quoted context omitted.

Go (not "Golang") has better compilation times than Rust and does not try to combine incompatible ways of using concurrency. I have the opposite dilemma to you, I want to learn to like Rust.

Let's try to settle the Go/Rust debate in this AoC sub-thread ^_^

Personally I like them both but I find the barrier to onboarding new devs is lower for Golang.

/s

Re: Advent of Code 2024

#438

Earlier quoted context omitted.

Last year I tried C on a real Amiga 1200 (using DICE, Matt Dillon’s compiler / runtime). I didn’t get very far, lack of memory protection makes things really hard. This year the Amiga has an 060 upgrade with an MMU, so perhaps I can figure out how to use that and have another go.

Heh. Yeah, a memfault tanking the machine is not conducive to iterative programming :o)

Honestly, I forgot all about that aspect of ancient programming. It probably made one more careful, or more patient. (Source: typing 6502 programs into a hex "monitor" which is a way to edit memory, view memory, and issue "jump to this memory address".)

Re: Advent of Code 2024

#439

Earlier quoted context omitted.

Good luck! Personally, I'm still going with CL but decided to try it in all the languages I "know" for the first day. Including C which doesn't have hash tables (inb4 hsearch)... what a pain, let me tell you. https://git.sr.ht/~q3cpma/aoc2024/tree/master/item/01 If you could post a repo link so I can look at some of the progress, I'd be grateful.

- bsearch + qsort is a great way to implement associative tables - you can implement a hash table in C in about 125 LOC and reuse it. - hash tables are not the only way to solve problems. hammer/nail

Also the TclHash table implementation is quite good and independent of the Tcl interpreter runtime.

Re: Advent of Code 2024

#440

My personal challenge last year was to solve everything on my mobile phone, using LLMs (mostly ChatGPT4 with code interpreter; I didn't paste in the problems, but rather described the code I wanted.) This year I'm declaring "Advent of Claude"! Challenge: Write a Claude custom style to solve Advent of Code puzzles within Claude's UI. Score: # adventofcode.com stars earned in 2 daily conversation turns. Fine print: web…

While I personally wouldn't find it a ton of fun to solve the puzzles that way, that's pretty cool. Nice work.

Is there a place where you're blogging this or at least aggregating the links so we can see how far you get with it as the puzzles get more challenging?

Post reply on HN