Eight months of interview prep I never used

· algorithms, interviews, career

Right after graduating, I decided I wanted a job at a big tech company, and I followed the standard playbook of the time: study algorithms until the whiteboard stops being scary. For about eight months, during 2017, that was my main project outside of everything else. The evidence still exists in a repository called coding-interview-solutions: 185 exercises solved in C++, most of them from interviewbit.com, which was a well-curated and free way to practice at the time — credit where it is due. I only pushed it to GitHub a couple of years later, but the exercises are from that period.

I took it seriously — probably too seriously. Each solution has the problem statement, the time and space complexity, and an explanation written for my future self. The README still carries a note that says the explanations “were intended to help me remember how I got to the solution”, which tells you I fully expected to come back and review all of this before the big day. At some point I even wrote a Node script that generates a static site, so I could browse my own solutions like a book — it is still online.

The distribution of the exercises says something about where the fear was: 28 dynamic programming problems, 21 on binary trees and binary search, 16 on graphs, and a long tail of arrays, strings, greedy, bit manipulation, and two pointers. Besides the exercises, I implemented the classics from scratch: an AVL tree, a segment tree, a trie, an LRU cache, Knuth-Morris-Pratt. Each one carefully explained, like this (the problem statement in the comment is interviewbit’s; the explanation is mine):

/**
 * Given two words A and B, find the minimum number of steps required to
 * convert A to B.
 *
 * Time complexity: O(M * N), where M is the length of string 1 and N is
 * the length of string 2.
 * Space complexity: O(M * N).
 *
 * Explanation: our dp variable will have size M * N, where M is the
 * length of string 1 and N is the length of string 2. The idea is that
 * for each pair of characters that we are looking at we decide which
 * operation we want to perform (insertion, deletion, replace). ...
 */

Then reality arrived, in two parts.

The first part: some of the big techs I applied to never called me. No interview, no whiteboard, no chance to use any of it. Perhaps it was my curriculum at the time — a recent graduate without big names on it — but the honest answer is that I don’t know, and that is exactly the problem. I had treated preparation as the whole game, when it was only the part of the game that was fully under my control. Studying received eight months of effort; getting the opportunity to be tested — the resume, the referrals, the visibility — received almost none. I assumed the pipeline was “prepare, interview, result”, and for some companies I never got past the first comma.

The second part: the company that did hire me ran an interview process that wasn’t based on algorithms at all. It was a good process — it just didn’t touch anything in that repository. I have been there for more than eight years now, and the number of times I needed to write a dynamic programming solution at work is easy to compute: zero.

So, was it eight months wasted? Not completely, but I think I should be careful with the romantic answer.

The romantic answer is that the knowledge stayed. It mostly didn’t. Today I could not write Knuth-Morris-Pratt or re-derive the edit distance recurrence without studying again; the explanations in that repository were written precisely because I knew this stuff doesn’t stick. What stayed is smaller and harder to put on a resume: I know these algorithms exist, I know roughly what they cost, and I can recognize the shape of a problem — “this is a graph”, “this smells like dynamic programming” — before I know how to solve it. The complexity instinct stayed too. To me that residue is real value, and I do like having it. It is just not eight-months-of- full-effort value.

There is also a cost that doesn’t show up in the repository. Eight months of that level of dedication meant saying no to almost everything else, and I paid for it in ways that took me longer to notice — less fun, less rest, less life around the studying.

If I could send one message back to the version of me grinding those 185 problems, it would not be “stop studying”. It would be: take it easy. Study, but live as well. There are parts of this process you cannot control, so don’t let it become your whole life — the door may never open, and the time you spend waiting in front of it never comes back.