The solutions in this repository are not necessarily the first things that I thought of as soon as I read a problem statement. Sometimes they aren't either things that I came up with completely by myself, but rather are a combination of my initial solutions and tricks or techniques used by other people's solutions that I stumble upon.
Roughly, the process I go through is as follows:
- Solve the problem without using any hints or external resources (often a quick and dirty implementation)
- Clean up my initial code so that it's not (as) embarrassing if someone ever reads it.
- If the problem is interesting enough, check other peoples solutions or approaches to understand them and maybe integrate them into the code. Sometimes I might leave my initial solutions in the repo if I think they're valuable for future reference. In cases where I don't and you want to see them, you might be able to find them in the commit history.
In an ideal world I would come up with beautiful bug-free code, but this is clearly not the ideal world :)