Hacker News new | ask | show | jobs
by dllu 4444 days ago
It just takes a bit of practice. Once you've seen a certain type of problem before, it is easy to identify other problems that can be somehow reduced to a known problem. Speed comes with practice too... soon, basic constructs like for-loops just get etched into muscle memory. Don't worry, I couldn't even solve a single problem in my first tryout at my university.

At my university, after a practice session, we sometimes discuss solutions to problems so that those who couldn't figure them out will know how to solve them in the future. After being told the solution to a problem you couldn't solve, you should try coding it up anyway.