4 ms·
I do practice and depending on my goals I take different approaches. The two main ones are: data structures and algorithms and rapid prototyping. The former i
by agentultra 3y ago
I do practice and depending on my goals I take different approaches.
The two main ones are: data structures and algorithms and rapid prototyping.
The former is basically leetcode stuff and straight forward. I want to be able to implement bread-first search without having to look it up. And I want to be able to do it without it occupying too much space in my mind. Repeated practice helps me retain this kind of stuff so that it becomes reflexive and almost like muscle memory.
The other kind of practice takes a bit more work. I did this for a period where I produced a body of small prototype games. The idea was to write them in the fastest way I could. I forgot all about coding practices that you would use in production code and went all in on, “how fast can I get from typing the first byte of source code to user interaction?”
For these projects I used a timer. Everything was permissible. It was code I wouldn’t use again so I didn’t care about it being reusable or readable or anything like that. I kept light notes on my experiences with each of them.
Prototyping is an oft-overlooked skill that can some times be useful. The idea is to write some code to hash out the idea; experiment with it in the fastest way possible with the goal of finding out whether the idea itself is viable. For a mountain of a task like developing a game, and in boring stuff like enterprise software, it’s useful to save yourself a bit of work from going down a dead end if you can scout ahead a little bit.