Citadel

Interview Question

Quantitative Researcher Interview
Citadel

Given an array of numbers: 1, 5, 3, 2, 4, 2, 3, 1, 2, 3, 2, 4, return another array where duplicate numbers are grouped in consecutive positions, maintaining the order of their first appearance. For example, the result should be: 1, 1, 5, 3, 3, 3, 2, 2, 2, 2, 4, 4.

Unlock the Full Solution

Enter your email to get instant access to the complete solution, explanation, and similar practice problems.

Insights on 100+ quant firms, understand where to apply, and maximize your chances.

Get the official 2025 QB Quant Firm Tier List

Check your email inbox — you should get the interview in 1-2 minutes!