← Citadel Interview Insights

Citadel·Software Engineer·Technical Phone Screen·Junior

JuniorPrefer not to say
Jun 2026

Summary

Quant-style probability question from Citadel, probably a phone screen or early technical round. Clean problem, straightforward if you know linearity of expectation, but easy to fumble the combinatorics under pressure.

Questions Asked (1)

Q1

You have 6 red cards and 4 black cards shuffled randomly into a line of 10. What is the expected number of adjacent pairs that share the same color?

Algorithms & Data Structures
Author's notes

The key move is recognizing you don't need to think about the full distribution, just treat each of the 9 adjacent slots independently.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Use linearity of expectation by defining indicator variables for each adjacent position and summing their probabilities. For each of the 9 adjacent pairs, compute the probability that both cards are red or both are black using combinatorics, then add these probabilities together.

Pro tip: Mention that linearity of expectation holds even when events are dependent, which is why we can simply sum the probabilities without worrying about correlations between adjacent pairs.

1. Define indicator variables

For each adjacent position i (from 1 to 9), let X_i be 1 if the two cards at positions i and i+1 have the same color, and 0 otherwise. The total number of same-color adjacent pairs is the sum of X_i.

2. Apply linearity of expectation

The expected value of the sum is the sum of the expected values: E[total] = sum_{i=1}^{9} E[X_i] = sum_{i=1}^{9} P(same color at positions i and i+1).

3. Compute probability for a single pair

For any adjacent pair, the probability both are red is (6/10)*(5/9) = 30/90 = 1/3. Similarly, the probability both are black is (4/10)*(3/9) = 12/90 = 2/15. So P(same) = 1/3 + 2/15 = 5/15 + 2/15 = 7/15.

4. Sum over all pairs

There are 9 adjacent pairs, so the expected number is 9 * (7/15) = 63/15 = 21/5 = 4.2.

5. Verify and present

Double-check the arithmetic and explain that the result is exact, not an approximation. Optionally, mention that the same method works for any counts of red and black cards.

Key Points to Mention

  • Linearity of expectation does not require independence.
  • Indicator random variables simplify the calculation.
  • Probability of same color for a single adjacent pair: (6/10)*(5/9) + (4/10)*(3/9) = 7/15.
  • There are 9 adjacent pairs in a line of 10 cards.
  • Final expected value: 9 * 7/15 = 21/5 = 4.2.
  • The method generalizes to any number of red and black cards.

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