DEV Community

Discussion on: What are your tips for coding interviews?

Collapse
heylucas profile image
Lucas • Edited on

I can share my experience as someone that conducts interviews often.

  • Warm up: The vast majority of candidates does not warm up before their coding interviews. Before your interview starts, grab one or two problems you already know how to solve and code it again, from scratch. That'll help get your gears going.
  • If you don't fully understand the problem, ask your interviewer for more info or tell them what you are not sure about. They'll be more than glad to explain it to you.
  • If the question you get allows for it, try to come up with test cases before you write the code. Just list something like '[input] -> [expected output]'. That'll give you some guidance when writing the code.
  • Once you are done coding, tell your interviewer you want to walk through your code. This is great signal for an interviewer and will certainly buy you points.
  • People often tell you to "think out loud" but not everyone is into that. Sometimes candidates get confused by trying to talk and write code at the same time. Instead, try first explaining the approach you'll take and then write code. Another option is to ask your interviewer if you can write the code first and then explain it to them later. I would totally accept that if a candidate asked.
  • If you know someone who's an interviewer, ask them to do a mock interview with you. Ask them to give you feedback as if you are a real candidate. Take notes and iterate.
  • If you don't manage to solve a problem on the spot, don't feel bad. The only reason the interviewer knows how to solve them is because they've asked the same question over and over again.