Comment by f1shy
Comment by f1shy 3 days ago
While is „only“ 12 days, are like 24 challenges. As no leaderboard is there, and I do it for fun, i will do it in 24 days.
Comment by f1shy 3 days ago
While is „only“ 12 days, are like 24 challenges. As no leaderboard is there, and I do it for fun, i will do it in 24 days.
One way I've found is to break the problem down, and think about each step in reverse. So for example, what does the final stage want to do in order to achieve the result in a simple way? It might be that to get the final result it needs to sum numbers, but also needs to know their matching index in another array, plus some other identifier you got from an as-yet-unwritten previous step. This means your final stage needs a bunch of records that are (number, idx, sourceId), which means the step before needs to construct them - what information does it need to transform into that?
Write the simple code you want to write, and think about what makes the prior step possible in the easiest way and build your structures from there, filling in the gaps.
Same. I usually try to use it as the "real-world problem" I need for learning a new language. Is there anywhere that people have starter advice/ templates for various languages? I'd love to know
- install like this
- initialize a directory with this command
- here are the VSCode extensions (or whatever IDE) that are the bare minimum for the language
- here's the command for running tests
learnxinyminutes.com is a good resource that tries to cover the key syntax/paradigms for each language, I find it a helpful starting point to skim.
Since the start, each problem has 2 parts (2 "stars"). Part one sets up the problem, ensures you have parsed the input correctly, etc. After submitting the correct answer to that part, part 2 is revealed, which sometimes expands the proplem space, adds new limits, etc. Something that solves part 1 might be inadequate for part 2.
Yes, but nothing (theoretically) stops him from saying: "congratulations, you have solved part 1, wait until tomorrow for part 2".
I think either the author thinks people appreciate more the 2 stages challenge, than having one problem each day; or, more likely, the whole "infrastructure" is already prepared for 2 stages challenges per day. And changing that meant more work, eventually touching literally 10 y.o. code. The reason for the reduced days is exactly the lack of time. I assume he preferred to have 12 days, and modify as little as possible the old code. Having 1 stage per day maybe would have been possible at the expense of having less challenges, which again defeats the purpose.
That sounds healthy! But I would note that there's been interesting community discussions on reddit in past years, and I've gotten caught up in the "finish faster so I can go join the reddit discussion without spoilers". It turns out you can have amazing in-jokes about software puzzles and ascii art - but it also taught me in a very visceral way that even for "little" problems, building a visualizer (or making sure your data structures are easy-to-visualize) is startlingly helpful... also that it's nice to have people to commiserate with who got stuck in the same garden path/rathole that you did.