Can anyone get good at the coding interview?

I just recently took the TripleByte test and while I passed the multiple choice section I totally bombed the round 2 online timed 15 minute problems. The first question I literally stared at for the whole 15 minutes and couldn’t even figure out what exactly it was asking me to do and timed out with zero code written (I won’t explain it in detail because I respect their platform and don’t want to give people an unfair advantage). The second problem I feel like I had a grasp of and was working on a solution but when I was almost done the time ran out so I had an incomplete solution. Also when thinking about the problem later i’m pretty sure my solution could be more efficient and it probably wouldn’t have been good enough to get me to the in person round.

Since I did so poorly I’ve started doing one 15 minute timed whiteboard problem a day (I then type my code into HackerRank and see if it passes), i’m starting with HackerRank’s interview preparation section and after I finish that i’ll do Cracking the Coding interview problems. The reason i’m only doing 1 a day is i’m not getting any interviews right now so i’m using my other time working through freeCodeCamp to get some React projects under my belt. I did the legacy front end certification about a year ago but used either vanilla js or Angular 1.x on all of the projects.

TripleByte’s failure email recommended The Algorithm Design Manual book to help with Algorithms so I ordered it on Amazon and will read it after I finish Clean Code (it was probably a bad choice for me to start with Clean Code because I don’t think people care about code quality as much as correctness and algorithm proficiency in new developers).

My major concern is that I took had Algorithm and Data Structures classes in college, I’ve done lots of coding problems on Codewars (https://www.codewars.com/users/MP7373), and yet I still failed so tragically on those 2 timed interview questions. I’ve heard that intelligence isn’t something that can be learned, i’ve heard (admittedly second hand) that IQ research says that even if the questions are changed the same people always end up at the top. I understand that IQ isn’t a comprehensive measure of intelligence but I fear that other things might mirror the futility of trying to improve it.

If i’m not one of the super genius people is it possible for me to ever get good enough at algorithms to get a job as a programmer? Like I graduated with a CS degree 2 years ago (with a really low GPA at 2.79) and if i’ve already taken this long and been unsuccessful does that mean I just don’t have the natural ability to ever cut it? These sorts of thoughts just eat at me so I had to voice them, I don’t want to make the atmosphere of this forum negative it’s just I needed to voice this somewhere.

15 minute is kind of short, but the triple-byte problems were actually somewhat standard if you look more into it.

From what the interviewer told me, they expect a solution but they don’t necessarily expect a good solution or actual code. What’s important is that you communicate your logic and maybe a have pseudo code in place so that even if you didn’t finish the code, they can understand what you were going for, also ask questions throughout, they are there to help you.

I know in my experience, one of my coding problems with them was more web-dev centric. Still the prompt asked for 30 minutes and it’s something I can only do with an hour minimum, even going in knowing the prompt.

I’m not good at them at all. I’ve gotten to a place where I can kind of read a prompt and have a sense of the type of question it is, and maybe talk my way through it by asking questions along the ways, but finishing in 15 minutes to 30 minutes is still not something I can do. If you do cracking the coding interview, you’ll find out that it is something you can get good at with enough practice, but boy the practice is grueling.

1 Like

I actually like doing the problems , I just fear that I won’t improve to be good enough. The only problems I don’t enjoy are the ones where I just hit a hard wall and can’t even plan out a solution, or even worse: don’t understand what is being asked.

Since reading cracking the code interview, this is my general thought process.

Is there a bruteforce solution, what seems like the most familiar optimization method for this bruteforce solution, am I tweakinging a algorithms I should already know. It tend to narrow down to a few algorithm tracks like Hashing, sorting, dynamic programming, binary search, tree search, back tracking, greedy algorithm, and graph problems… I’m there.

I don’t crack it all the time, much less with time limit, but at least I don’t completely draw a blank

I also stared at one of the problems on triplebyte like “What?” If they aren’t going to explain them super well they should at least be there so you can ask questions.

I’m not sure who triplebyte is looking for. A lot of the questions are pretty basic, then the coding test is very…niche.

Hmm, my experience was that the interviewer was online throughout. He even gave me hints

I didn’t get to the in person round, I failed on the round 2 which is 2 15 minute problems.

I’ve never attempted TripleByte before, but I have done lots of online coding tests for job applications, usually on HackerRank.

With that in mind, I’d say that there are a few things that you (not you specifically, speaking generally here) should really know before attempting any kind of coding test, particularly the timed ones that employers often give for job applications:

  • You need to have really good knowledge of at least one widely-used programming language, whether it’s Java, Python, Ruby, JavaScript, et al. By “really good,” you should know all the major features of the language, quirks of the language, and how to work with any data structure that you might come across in an average scenario—arrays, linked lists, and trees. For example, in JavaScript you should be intimately familiar with all of the built-in array methods and how to quickly determine whether an element is in an array, and the functional aspects of JS. A lack of in-depth knowledge on the programming language of your choice can make or break the difference in getting to a solution quickly—i.e., a newbie to JS will almost certainly take “the long way around,” while someone more proficient might realize that a few clever uses of the array methods will result in getting to the solution faster, as well as a more efficient solution. Basically, you need to know your tools adequately enough in order to beat any timer (and get to an in-person interview stage).

  • Knowledge of basic data structures is incredibly important, and arguably more important than knowledge of algorithms. Learn and master all of the most common data structures in the programming language of your choice. This is probably the one thing that will end up helping you the most when it comes to coding tests.

  • You should be familiar with the types of questions these tests tend to ask. And yes, that does mean you should basically practice before attempting one for real for an employer. The more coding tests you take, the more experience and knowledge you’ll pick up on recurring types of questions and approaches to solutions. This is important because this way, you know what topics to study! Studying “data structures and algorithms” is all well and good, but that’s also incredibly broad. That doesn’t tell you the specific areas that you need to study.

  • There are times when you’ll never be able to guess the topics on a timed test, and they can be incredibly domain-specific. This really just comes down to studying and learning as much as you can. Read as many books as you can, take as many online courses as you can, etc. Soak up as much knowledge as possible. You never know when a small piece of trivia will come in handy one day.

  • Always save your solution code (along with the question!) on your local computer. Having those for future reference will allow you to go back and learn from your failures.

  • If you’re taking a timed test and you know for certain you won’t get it done on time, COPY THE QUESTION*** first! Then, write a pseudocode answer, or even just comments. And then, take the time to figure out how to do it after the test is over. This way, even though you “failed” the test, you can still learn something from it by putting in the time to figure it out anyway.

  • Don’t start out practicing by putting yourself on a timer right away. First make sure that you know how to solve a variety of problems without the pressure of a timer. Once you’re more comfortable and have more experience & knowledge, then put yourself on a timer.

*** Some tests, especially those on HackerRank, try to block you from copying the question using standard methods (Ctrl-C and screenshots). Be prepared to have to copy the question by typing it out manually!

3 Likes

I’m already proficient enough to have the timer and am knowledgeable of most of the shorthand array methods(map, filter, reduce, slice, splice, for each, spread, etc).

I have a white board and have been doing problems and when the 15 minutes runs out I take a picture of my hand written code on the board and type it into HackerRank and see if it passes. If it doesn’t pass I fix my mistakes in the editer or spend more time to actually solve the problem if my attempted solution didn’t work at all. I’m sure once I get to the more difficult problems I won’t always finish in 15 minutes but it’s good practice not having intellisense to suggest methods and auto fill. I’m mostly worried about my ability to solve more complicated problems in time (or at all), not so much my language familiarity.