Fin (Intercom) interview prep

50 Algorithm & Data Structure Problems

This set was built from real research into Fin's public engineering writing (fin.ai/research, Intercom help docs, the Fin-over-email engineering post) plus common algorithm categories that show up in ML-infra and conversational-AI engineering interviews. Problems are ordered by importance, not just difficulty: the first 10 map directly to details Fin's own team has published about their retrieval and reranking pipeline; the next 10 are adjacent infra patterns; the rest are classic medium/hard algorithm categories given a light Fin-style framing.

How to read the grounding badges: every problem page states plainly whether its scenario is Confirmed — backed by a specific source in Fin's own public research — or General Pattern — a plausible, industry-standard scenario that is not a confirmed detail of Fin's actual implementation. A couple of intuitive guesses (e.g. DBSCAN-based query dedup) were explicitly checked and refuted during research, so they're labeled as inferential exercises rather than facts.

What's on each problem page

  • The scenario, framed around Fin's support/ML-infra domain, with its grounding badge.
  • The actual stub function signature and docstring from the corresponding .py file in ../ (the code you'd run locally to practice).
  • A step-by-step walkthrough of the solution approach — the reasoning, not just the final code.
  • A "how to recognize this pattern in general" section, for transferring the approach to a novel problem in an interview.

Running the code yourself

Every problem has a matching pair of files one level up, in code/problems/src/:

src/1_top_k_retrieval_candidates.py            # stub — implement the function, then run it
src/1_top_k_retrieval_candidates_solution.py   # reference solution — run it directly

python3 N_slug.py runs your implementation against the built-in test cases and asserts they pass. python3 N_slug_solution.py runs the reference solution and prints a step-by-step trace of its execution.

Start with Problem 1: Top-K Retrieval Candidates, or jump to any problem from the sidebar.