TomoLink
Technical Interview Guide

Coding Interview Preparation Guide 2025

Learn the patterns, practice the right way, and master the art of thinking out loud in live coding interviews.

10 Must-Know Coding Patterns

90% of coding interview problems can be solved with these 10 patterns. Learn the pattern, not just the problem.

1

Sliding Window

Example problems: Longest Substring Without Repeating, Max Sum Subarray of K

When to use: Contiguous subarray or substring problems with a condition

2

Two Pointers

Example problems: Two Sum (sorted), 3Sum, Container With Most Water

When to use: Pair or triplet problems in sorted arrays

3

Fast & Slow Pointers

Example problems: Cycle detection in linked list, Middle of Linked List

When to use: Cycle detection, finding middle element

4

Binary Search on Answer

Example problems: Koko Eating Bananas, Minimum Days to Complete Tasks

When to use: Finding minimum/maximum value satisfying a condition

5

BFS (Level Order)

Example problems: Binary Tree Level Order, Shortest Path in Matrix, Word Ladder

When to use: Shortest path, level-by-level traversal

6

DFS (Backtracking)

Example problems: Subsets, Permutations, N-Queens, Sudoku Solver

When to use: Generating all combinations, constraint satisfaction

7

Dynamic Programming

Example problems: Knapsack, Longest Common Subsequence, Coin Change

When to use: Overlapping subproblems with optimal substructure

8

Merge Intervals

Example problems: Merge Intervals, Insert Interval, Meeting Rooms

When to use: Overlapping ranges or time scheduling problems

9

Monotonic Stack

Example problems: Next Greater Element, Largest Rectangle in Histogram

When to use: Next/previous greater/smaller element problems

10

Top-K Elements (Heap)

Example problems: Kth Largest, Top K Frequent, Merge K Sorted Lists

When to use: Finding K largest/smallest elements efficiently

During the Interview — Dos & Don'ts

Do This

  • Ask clarifying questions before starting to code
  • Think out loud — say your approach before coding it
  • Start with brute force, then optimize
  • Trace through your solution with the example
  • State time and space complexity before finishing
  • Handle edge cases explicitly
  • Write clean, readable code — avoid single-letter variables

Avoid This

  • Jump straight into coding without a plan
  • Stay silent — interviewers want to see your thought process
  • Optimize prematurely before a working solution exists
  • Ignore edge cases (empty array, single element, negative numbers)
  • Write messy or unreadable code
  • Give up if stuck — ask for a hint after 5 minutes
  • Memorize solutions instead of learning patterns

The UMPIRE Framework for Coding Rounds

U

Understand

Re-read the problem. Identify: input format, output format, constraints, and what 'optimal' means.

M

Match

Match the problem to a known pattern (sliding window? BFS? DP?). What data structure fits?

P

Plan

Outline your algorithm in plain English before coding. Agree on the approach with the interviewer.

I

Implement

Write clean code. Narrate as you type. Use meaningful variable names.

R

Review

Trace through with the sample input. Check edge cases manually.

E

Evaluate

State time and space complexity. Suggest optimizations if you see them.

Coding Interview Practice Plan

Week 1-2

Easy problems — Arrays, Strings, Hashmaps. Solve 50 problems. Focus on getting working solutions, not speed.

Week 3-5

Medium problems — Trees, Linked Lists, Recursion. 75 problems. Start recognizing patterns.

Week 6-8

Patterns — DP, Graphs, Advanced Trees. 50 problems. Learn pattern before problem.

Week 9-10

Mock interviews — time yourself to 45 min per problem. Use Pramp, Interviewing.io, or peers.

Practice coding with real company questions

TomoLink curates company-specific DSA questions so you practice exactly what each company tests.

Explore Company Questions

Related Guides