3x + 7y = 10k find ab
Product of smallest integer solutions is an easy quant interview question on Pure Math, reported to have been seen at Goldman Sachs, IMC, Jane Street and WorldQuant.
MyQuantPartner is not affiliated with, endorsed by, or sponsored by these companies, and all trademarks belong to their respective owners.
This exercise sits at the intersection of number theory and algebra, a staple of pure mathematics used in many quant interviews and quant prep courses. It focuses on integer solutions to a linear relation, a classic Diophantine setup that appears frequently in written tests and online assessments for roles in quantitative finance. Candidates must be comfortable moving from a single example to a full parametric family of solutions.
It trains your understanding of greatest common divisors, integer linear combinations, and how solution sets form structured patterns rather than isolated points. Working through it reinforces comfort with modular arithmetic, solution parametrization, and reasoning about minimal positive representatives within an infinite discrete family.
This matters for a quant interview because it tests algebraic rigor under time pressure. Interviewers see whether your quant prep has built genuine structural insight, not just rote formula recall, and whether you can argue cleanly and systematically about integers.
What it tests
When solving linear Diophantine equations of the form $ax + by = c$ with coprime $a$ and $b$, the key is that all integer solutions can be systematically generated from any particular solution by exploiting the fact that $a$ and $b$ are relatively prime. The general solution takes the form $x = x_0 + (b/d) n$, $y = y_0 - (a/d) n$, where $(x_0, y_0)$ is a particular solution, $d = \gcd(a, b)$, and $n$ is any integer. This structure arises because adding $b$ to $x$ and subtracting $a$ from $y$ preserves the value of the linear combination, due to the coefficients' coprimality. The reason this works is that the set of all integer solutions forms a lattice along a line in the $(x, y)$-plane, and the step sizes are determined by the coefficients themselves.
Practise this question with written feedback, or hear it in a spoken mock interview.
Get started free