Skip to content

How to prepare for a technical interview

my first blog post

Technical interviews for engineering roles test two things: whether you can solve problems in code, and whether you can explain your thinking while you do it. Both improve with practice, so the best preparation is a few weeks of steady work rather than a cram the night before.

Know the common data structures (arrays, linked lists, stacks, queues, hash maps, trees, heaps and graphs), what each operation costs in Big-O terms, and when you’d pick one over another. Be comfortable with binary search, sorting, recursion, and breadth-first and depth-first traversal of trees and graphs. Practise writing them in the language you’ll use in the interview, such as Python or Java, so you aren’t fighting the syntax.

For mid-level and senior software roles, expect a design question such as “design a URL shortener”. Review the building blocks: horizontal scaling, caching, load balancing, SQL versus NoSQL databases, replication and message queues. What interviewers look for is the trade-offs, for example why you’d add a cache and what happens when it goes stale, not a single right answer.

Work through problems on LeetCode, HackerRank or Codewars. Time yourself so you get used to coding under pressure. Mix easy problems, which build speed, with harder ones, which teach you new patterns. When you can’t solve one, read a solution, then solve it again from scratch a few days later.

Most interviews are on a whiteboard or a shared editor, and the interviewer is grading your process as much as the result. A routine that works:

  1. Restate the problem and ask about inputs, edge cases and constraints.
  2. Walk through a small example by hand.
  3. Describe a brute-force solution and its complexity.
  4. Improve it, then write the code.
  5. Test it against your example and the edge cases.

Ask a friend or colleague to run a mock interview and treat it like the real thing, from introductions to the final questions. Afterwards, note where you got stuck or went quiet, and work on those areas before the next one.

Read the job posting and make sure you can talk about the languages, frameworks and tools it lists. If you’ve used them, have a project ready to describe. If you haven’t, build something small with them before the interview.

© 2026 David Li · Home · Blog · RSS ·Classic site · Built with Astro, Starlight and three.js · Logos:Font Awesome Free (CC BY 4.0)