← Optiver Interview Insights

Optiver·Data Scientist·Technical Phone Screen·Intermediate

IntermediatePrefer not to say
May 2026

Summary

Interviewed for a Data Scientist role at Optiver and got hit with a full constraint-satisfaction puzzle design question. Not what I was expecting from a quant-adjacent firm but in hindsight it makes sense given how much they care about algorithmic thinking.

Questions Asked (1)

Q1

Design and implement a solver for the Skyscraper logic puzzle on an N×N grid. Walk through your modeling choices, search strategy, pruning techniques, and how you'd verify if a solution is unique. Also cover expected input/output format and worst-case complexity.

Algorithms & Data StructuresSystem DesignTechnical Trade-offs
Author's notes

This one took me a second to even parse.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by formalizing the puzzle as a constraint satisfaction problem (CSP) with variables for each cell's height and constraints from row/column clues. Then propose a backtracking search with constraint propagation (e.g., maintaining possible values) and pruning techniques like forward checking and arc consistency. Finally, discuss uniqueness verification via exhaustive search or by checking for multiple solutions, and analyze complexity.

Pro tip: Emphasize the trade-offs between different modeling choices (e.g., cell-based vs. permutation-based) and how they affect pruning effectiveness and complexity. Mention that for N up to 5 or 6, brute-force with pruning is fine, but for larger N, more advanced techniques like SAT solvers or exact cover may be needed.

1. Model the Puzzle

Define variables (cells) with domains {1..N} and constraints: each row/column is a permutation, and clue constraints (visible skyscrapers from each direction).

2. Choose Search Strategy

Use backtracking search with variable ordering (e.g., most constrained variable) and value ordering (e.g., least constraining value).

3. Apply Pruning Techniques

Implement forward checking, arc consistency (AC-3), and clue-based pruning to reduce the search space.

4. Verify Uniqueness

After finding a solution, continue search to see if another exists; if none, solution is unique. Alternatively, use a SAT solver with a blocking clause.

5. Analyze Complexity and I/O

Discuss worst-case complexity (exponential in N^2) and expected input/output format (e.g., grid of clues, solution grid).

Key Points to Mention

  • Constraint satisfaction problem formulation with variables, domains, and constraints.
  • Backtracking search with heuristics like MRV (minimum remaining values) and LCV (least constraining value).
  • Pruning techniques: forward checking, arc consistency, and clue-specific pruning (e.g., using permutations that satisfy clues).
  • Uniqueness verification by searching for multiple solutions or using a SAT solver with blocking clauses.
  • Input/output format: e.g., input as a list of clues (top, bottom, left, right) and output as an N×N grid.
  • Worst-case complexity: O(N!^N) for brute force, but pruning reduces practical complexity; mention that for N>6, more advanced methods may be needed.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.