InterviewLegend

What Two Sigma Tests

Alex Chen11 min readGuide updated
In this lesson
  • Know the three coding stages, the languages allowed and the AI rule
  • Know what the rubric grades, testing included, and why running code matters
  • Know the problems candidates report most, newest first, and where each is worked

Two Sigma doesn't hide much about its software engineering loop. Its interviewing page says the technical half is "broken up into three 60 minute interviews", covering data structures, algorithms and object-oriented design, in "a shared codepair environment". You can write in C, C++, Java or Python. Before that come an online assessment and a live screen.

What the page doesn't say is how repetitive the questions are. The same two OA problems have turned up since 2021 and were still reported in 2026. The screens keep returning to the same handful of build-it-yourself prompts. As one candidate put it back in 2022, "their question bank is not big". That's good news. You can prepare for the real problems instead of guessing.

The Two Sigma angle
Write code that runs, then prove it with tests. Back in 2020 a Two Sigma employee said the main difference from Google questions is that "your code needs to run". Testing is one of the five things the rubric names. Run your solution against small cases you wrote yourself, and talk through each one, before you call it done.

The Two Sigma coding rounds

The online assessment. Two problems on one timer, usually on HackerRank, though a few candidates around 2021 to 2023 got CodeSignal. Most candidates from 2021 through late 2025 had 75 minutes, and a couple in 2025 had 120. Candidates call it long-winded rather than hard. Don't count on partial credit, either. A Two Sigma employee wrote in June 2026 that "Nowadays you do need 100% to move on". The pair has its own lesson, The Two Sigma Online Assessment.

The live technical screen. One problem for the hour, in a shared pad with an interviewer. A quantitative software engineer in July 2026 did theirs in HackerRank's live coding pad. The problem is usually something you build rather than a puzzle you spot: a hash map with no built-in hash table, a small SQL-like database, an encode and decode pair, an order matcher. The follow-ups probe tie-breaks, why you picked your data structure and how you tested it. Finishing isn't always required. An April 2026 candidate ran out of time on the database and said nobody had asked them to finish it.

The technical interviews. Officially three 60-minute interviews, and you can be stopped after them. Recent candidates describe LeetCode medium to hard. One Two Sigma employee put it more bluntly in February 2026: "Just leetcode hard for mid level and below". Some candidates also get a class-design round, which has its own section below. The page also says you "may be asked to take part in a systems-design exercise", which the system design overview covers by level.

Some team roles skip most of this. Recruiter-sourced quantitative engineering and GenAI roles in 2026 ran one HackerRank coding round, the order matcher, and then a manager or senior engineer deep dive on past work. One 2025 QSE screen also slipped in a couple of behavioral questions, like why you're leaving.

The SWE interviewing page is explicit: "Use of ChatGPT or any other AI tool is strictly prohibited. Any perceived usage of these types of tools could result in disqualification of your application for employment." It covers the assessment and every interview. No candidate report from 2025 or 2026 describes an AI-allowed round.

What the technical interview grades

The rubric is published, so quote it to yourself: "The areas we grade for may include: coding ability, computer science knowledge, testing, design/architecture, and general problem solving ability." Testing sits in that list next to coding. At most companies it's an afterthought. Here it's a line on the scorecard.

Candidates describe the same thing from the other side. A quantitative engineer who got the order matcher in July 2026 wrote that "The core of it wasn't just getting the happy path to run". Their follow-ups were about which tests would raise confidence, why the output differed from the sample, and how orders at the same price get ordered. A senior candidate in 2022 said "You had to come up with test cases". Expect to write your own.

Interviewers aren't trying to trip you, either. The official page says they "want you to do well and are happy to give you hints if you get stuck while developing your solution." Take the hint and keep moving. Plenty of candidates say they ran out of time, and a hint costs far less than ten stalled minutes.

Pick deterministic tie-break rules early and say them to your interviewer. The order matcher, the IPO allocation and the Huffman encoder all live or die on how ties are broken. Then run three small tests you wrote, including the ugly edge case, before you say you're done.

The Two Sigma coding questions candidates report most

The top two bars are a pair, since the OA gives them together. Almost everything else is a simulation or a build-from-scratch task, and very little of it is a pattern you could lift from LeetCode.

IPO share allocation (OA)11
Split a drainage tree (OA)11
Order matching engine8
a Premium question6
a Premium question5
Huffman-style encode and decode3
Hash map from scratch2
Separate candidates naming each SWE and QSE coding problem, 2020 to 2026. Two Sigma publishes no breakdown. The OA pair almost always comes together.

One prompt is missing from the chart because it lives in System Design. The memory allocator, malloc inside a fixed array, came up for six candidates from 2022 to 2026, the newest an intern's first technical in October 2026. If you count it, it ties with the database, right behind the order matcher.

The problem families, newest first

The OA pair. In the usual version, IPO share allocation hands you bids with an id, a share count, a price and a timestamp. You fill from the highest price down, and bidders tied on price take one share per turn in timestamp order. You return who got nothing. The drainage problem gives a tree as a parent array with a flow at each node. Cut one edge so the two halves are as close in total flow as possible. Candidates describe it from October 2021 to July 2026. The traps are the tied group's turn order and sizes up to around 100,000 nodes.

The drainage split comes down to one pass of subtree sums. In a version where the root's parent is -1, the core looks something like this.

python
def min_split_difference(parent, flow):
children = [[] for _ in parent]
root = parent.index(-1)
for node, up in enumerate(parent):
if up != -1:
children[up].append(node)
order = [root] # parents always come before their children
for node in order:
order.extend(children[node])
subtree = list(flow)
for node in reversed(order): # so every child is added before its parent
if node != root:
subtree[parent[node]] += subtree[node]
total = subtree[root]
return min(abs(total - 2 * subtree[node]) for node in order if node != root)

The loop over order replaces recursion on purpose. A chain of 100,000 nodes would blow Python's default recursion limit, and the tree can be that big. OAs in October 2025 and August 2026 had a balanced bracket split with wildcards and a closest pure color parser instead. Each came up only twice, so give them less time.

Order matching. The most reported live-screen problem from December 2024 to July 2026, for SWE, QSE and GenAI-team candidates alike. In the usual shape, limit orders arrive in sequence. Bids sit in a max-heap and asks in a min-heap. When they cross, you trade at the resting order's price, handle partial fills and print the trades and the final book. Follow-ups ask about ties at the same price, order ids that arrive out of order, and whether a heap is the right structure at all. Order Books & Matching builds it part by part.

Build it from scratch. A Premium question came up in January, April and July 2026: tokenized commands to create a table, insert rows and select with conditions. Candidates say it's long and hard to finish. The Huffman-style encoder and decoder (newest December 2025) comes with a long statement. One candidate spent about ten minutes just clarifying it, and both a deterministic tie-break and the one-character case are part of the spec. A Premium question came up in screens from September to November 2025, and a January 2026 round asked for a class that merges delta-encoded sensor streams. All four are in Build From Scratch.

Graphs and trees. A Premium question asks for the best product of rates from one currency to another, using each currency at most once. Plain DFS times out, so you memoize. Reports run from 2022 to January 2026. A November 2025 onsite asked for the largest group of people where no two know each other, inside a tree. See Currency Paths & Tree DP.

Older problems. Six problems last asked in 2025 or earlier sit in one lesson at the end, each labelled with its years. An October 2025 OA had a traffic monitor and pipeline throughput, August 2025 rounds had capital selection and a flooding grid, and a 2025 loop had a prefix trie. Multiply Strings with negatives dates from 2022 and 2023. Work them last.

The class-design round and debugging

Three candidates from November 2025 to March 2026 describe a class-design or object-oriented round next to the algorithm rounds. An intern called round one "pretty standard leetcode medium with some system design sprinkled in". A new grad in January 2026 called the block "a mixture of leetcode and class design". None of them named the prompt.

Prompts that do have names sit in the System Design section, though you write them as running code. The memory allocator is the most reported. Design a Connect-N Game came up in a Houston round titled "System Design, primarily object-oriented programming" in March 2025 and in a 2021 onsite. Build one of each in a plain editor with tests and you've covered the shape.

New grads should also expect code they didn't write. Asked about system design for new grads in April 2025, a Two Sigma employee said there's none, but offered an example of the extra work: messy code with bugs, where you "fix the bugs and refactor the code." A candidate from about 2023 described a design-based interview spent correcting bugs in "a decently long class". Practice by reading an unfamiliar class, writing a failing test for each bug, then fixing it.

Two Sigma LeetCode tagged vs what Two Sigma asks

The LeetCode company tag for Two Sigma mixes years, roles and rounds into one list. That's a poor match for a loop whose bank is this small. The two OA problems have no LeetCode equivalent. The drainage split is close to Maximum Product of Splitted Binary Tree, but you minimize a difference instead. Order matching is closest to Number of Orders in the Backlog. The hash map is Design HashMap plus resizing, which the LeetCode version doesn't require. The database and the Huffman coder aren't on LeetCode at all.

The tag still has a job. The three technical interviews do pull LeetCode medium to hard problems, and the currency problem is a cousin of Evaluate Division. So split your time. Practice the actual Two Sigma problems for the OA and the screen, then use tagged and general medium-hard lists for the technical block. A 2022 reply summed up the reuse: "two years on and it's still the same few questions".

SWE, QSE and the other tracks

This guide covers the software engineer and quantitative software engineer loops. Both start with an online assessment, and the order matcher shows up in both. QSE loops lean more on math and modelling. A candidate in March 2026 had heard the two are tested differently, and a Two Sigma employee in September 2026 called quant dev interviews very different from SWE ones. A July 2026 QSE round 2 went deep on scaling an optimizer workflow, which the project deep dive lesson works through.

PhD SWE interns, research interns and data scientists often get a different OA: a linear interpolator, an online regression and a pandas analysis. It has its own lesson, The Research & PhD Intern OA. Data science and ML intern coding rounds beyond that OA are a separate track this guide doesn't cover.

The Two Sigma angle
Prep in pipeline order. Get the OA pair to a full pass first, since anything short of a full pass can end the process. Then build the order matcher and one from-scratch structure with your own tests. Leave LeetCode medium-hard sets and one class-design rep for the technical block. QSE candidates add a scaling story about a system they built.

Practice by problem family

The lessons run in study order, newest and most reported first. Start with the OA, because it decides whether you get a screen at all. After the live rounds comes the research OA, and the problems from 2025 and earlier sit at the end.

The Two Sigma Online Assessment

IPO share allocation and the drainage tree split, the OA pair since 2021, with both traps worked.

Order Books & Matching

The most reported screen problem in 2025 and 2026: price-time priority, partial fills and the follow-ups.

Build From Scratch: Database, Stream Merger, Huffman & Hash Map

The 2026 a Premium question and a Premium question, plus the encoder and hash map from late 2025 screens.

Currency Paths & Tree DP

The best exchange rate over simple paths, and the a Premium question in a tree.

The Research & PhD Intern OA

The separate OA for PhD SWE interns, research and data science candidates. Full-time SWE candidates can skip it.

Older Practice Problems (2022-2025)

Six older OA, onsite and screen problems, each labelled with its years.

Common questions

What is the Two Sigma coding interview like?

An online assessment with two problems, then a live screen with one problem, then three 60-minute technical interviews in a shared pad. The OA and the screen lean on simulations and data structures you build yourself. The technical block adds LeetCode medium to hard problems and, for some candidates, a class-design round. Your code has to run.

What questions come up in the Two Sigma technical interview?

In 2026 the OA is still IPO share allocation plus the drainage tree split. Screens most often bring the order matching engine, a Premium question, a hash map from scratch or a Huffman-style encoder. Technical interviews add medium-hard algorithm problems and sometimes a coded design like the memory allocator.

Is Two Sigma LeetCode tagged worth doing?

For the technical block, yes. For the OA and the screen, the tag misses the problems that repeat most, because they have no close LeetCode version. Practice those directly.

What language can I use?

C, C++, Java or Python, per the official page. Pick the one you write fastest and can test quickly.

Can I use ChatGPT or Copilot?

No. Two Sigma bans any AI tool in the assessment and every interview, and says perceived use could disqualify you.

Do I have to finish the problem?

Not always. An April 2026 candidate didn't finish the database screen and said finishing wasn't required. The OA is different: a Two Sigma employee said in 2026 that you need a full pass to move on.

Key Takeaways

  • ✓Two Sigma runs a two-problem OA, a one-problem live screen and three 60-minute technical interviews in a shared pad.
  • ✓The question bank is small and reused. The OA pair and the order matcher lead 2026 reports.
  • ✓Testing is on the published rubric, code must run, and AI tools are banned.
  • ✓Practice the real Two Sigma problems for the OA and screen. Use LeetCode medium-hard for the technical block.

Free Two Sigma interview pages

Two Sigma interview guide

Know what Two Sigma asks before you walk in.

21 coding · 4 system design · 13 behavioral questions

Get Premium$49 a year · Instant access
Or start freeNo card.

Get their questions first.

Your Prep PlanHad your Two Sigma interview?How we research

InterviewLegend is independent and not affiliated with or endorsed by any company it covers.