If you're an experienced quant applying for a new role in an investment bank, you might presume that you'll be able to walk through the interview process. Not necessarily.
In the past five years, Dirk Bester, a finance quant with a PhD in Bayesian algorithmic design, has interviewed everywhere from Barclays to Blackrock, to BNP Paribas, Cumulus, G-Research, Goldman Sachs, GSA Capital, J.P. Morgan, Man Group, Oxford Asset Management, RBC, RBS, Squarepoint Capital, Two Sigma, UBS, and...Winton Capital. Bester has written a detailed guide to his quant interview experiences and posted it to Github. Whether you want to be a quant/strat, or you simply want to be in with a chance of remaining employed in finance in 2025, it's mandatory reading.
We caught up with Bester this week (August 2020). Bester has a job but occasionally still interviews at rival banks. At the same time, other recent quant interviewees also send him the questions they've recently encountered. He says it's becoming apparent that the questions being asked in quant interviews are evolving.
"There are more coding questions and coding types of brain teasers," says Bester. "If you go for a quant finance interview today, you will be required to know a lot about algorithms and data structures. The questions you encounter are similar to the questions you get at Google or Facebook."
Bester says quant interviewees today need to know how to code in either Python or C++ and to be prepared for detailed questions about machine learning and coding in a production environment. This is in contrast to, say - 10 years ago - when an interview for a quant job in finance was all about assessing mathematical aptitude and familiarity with stochastic calculus.
Contrary to some suggestions that banks' interviews are easy compared to interviews with top tech firms, Bester says they're still incredibly hard. "You've got the same level of difficulty as before, but with more of a tech focus. This is because most quants in banks today are expected to write production code."
Bester says the new interview format can be a challenge to quants who haven't interviewed for a while. "It's a huge shock," he says. "People with a lot of experience are being asked to write algorithms to solve brainteasers during the interview process. A lot of people think they are senior enough to avoid that."
These are some of the new generation of questions that Bester says you should expect:
In object-oriented programming, when would you use inheritance, and when would you use composition?
- Write a function to determine whether a linked list is circular
- What is the difference between lasso and ridge regression? What is an L-1 and L-2 norm, and what would a L-0.5 norm look like?
- What is meant by "drop-out" when we are working with Neural Nets?
- Write a function to generate all permutations of a given string.
- How would you use the linux command line to find all the python files on your computer that contains a specified string?
- Write an algorithm that takes a list and shuffles all the elements in it randomly. Do it in-place.
By comparison, here are three of the easiest questions and answers from Bester's guide. There are many far harder ones listed in the full iteration on Github. If you can't answer any of these questions, your chances of getting a quant or a strat job in an investment bank will be minimal.
1. The murderer question:
You are guarding 100 murderers in a field, and you have a gun with a single bullet. If any one of the murderers has a non-zero probability of surviving, he will attempt to escape. If a murderer is certain of death, he will not attempt an escape. How do you stop them from escaping?
The murderer answer:
Bester says that solving this question requires you to make some possibly incorrect assumptions about the rationality of the criminals involved. It also requires you to clarify whether you will be able to talk to the murderers (through a megaphone) before they make a run for it. Assuming the murderers are rational and you do have a megaphone, this is the solution...
"Start with n = 1," says Bester. "Were there a single murderer, you would shoot him if he tried to escape. Because he would know the probability of survival is zero, he wouldn’t try. Were there only two murderers in the field, each would have a probability of surviving of 0.5, and thus would attempt to escape. But, if you told one of the two that you would definitely shoot him if the two of them attempted to escape, he wouldn’t make an attempt, bringing you back to the situation with a single murderer."
From there, Bester says you need to generalize this outcome to three or more murderers. For any given group, you need to identify one murderer as the so-called “sacrificial escapee”, and make to him aware of it. One way to do this is to every murderer in the murderer sub-group a number from 1 to n and to tell them that if any group attempts to escape, the group member with the highest number will be shot. That way, no group will attempt an escape.
2. The airplane seating question
Bester says he was asked this question repeatedly in successive finance interviews. It's sometimes called the "drunken passenger" and goes like this:
One hundred people are in line to board a plane which has exactly 100 seats. Each passenger has a ticket assigning them to a specific seat, and the passengers board one at a time. The first person to board is drunk, picks a random seat, and sits in it. The remaining passengers board; if they find their assigned seat empty, they sit in it. If they find their seat taken, they pick a random seat to sit in. Everyone boards, and is seated. What is the probability that the final person who boards gets to sit in their assigned seat?
The airplane seating answer:
Bester says this question is so well known that it's detailed in classic books on quant interviews by Mark Joshi and Paul Wilmott.
He cites Wilmott's solution. - Start by considering just two people: the drunkard and yourself. In this case, the drunkard will sit in his correct seat 50% of the time and you will get your allocated seat. In another 50% of cases, the drunkard will sit in your seat and you will be displaced. Then, expand this to three people: the drunkard either sits in his seat, your seat, or in the other person (Peter's) seat. The chances of him sitting your seat and his seat are the same and therefore balance out. If the drunkard sits in Peter's seat, the outcome will depend on whether Peter sits in the drunkard's seat or yours. So, there's a 50% chance that you'll get to sit in your allocated seat (and this holds however many people there are).
3. The sock question
A bag contains N socks, some of which are black, and some of which are red. If two random socks are picked, the probability that they are both red is 1/2. What is the smallest possible value of N for which this is possible?
The sock answer:
Bester says you solve this as follows:
Let Ri indicate the event where the ith sock is red.
Let r be the number of red socks in a bag of N socks.
If N = 2, both socks will be red with certainty, so this cannot work. When N = 3 you have...
...and there aren’t any integer values of r that would make this hold.
But, when N=4, you get the following solution:
Therefore, says Bester, the smallest possible value of N is four. Simple! Or not.
Quant questions of your own:
If you want to impress at a quant interview, Bester also suggests a number of questions you might want to ask yourself, partly to establish whether the team you're joining is working with the latest technologies. These include the following:
What operating systems do the team use?
What are the proportions of Windows, Apple, GNU/Linux?
What does the team use for technical documentation? LaTeX, Wiki, Word, or nothing?
What software does the team use for version control? Svn, Git, Mercurial, Team Foundation Server, or appending V1, V2, V3 to foldernames?
What programming languages does the team use? R, Python, C++, Julia, Matlab? For data analysis? For scripting? For production?
Is the team Bayesians, frequentists, or whatever gets the job done?
Are modellers expected to write the code to implement their models, or is this handled by developers? •
Is there a formal process for requesting the installation of new software libraries?
Photo by Charles Deluvio on Unsplash
Have a confidential story, tip, or comment you’d like to share? Contact: email@example.com in the first instance. Whatsapp/Signal/Telegram also available. Bear with us if you leave a comment at the bottom of this article: all our comments are moderated by human beings. Sometimes these humans might be asleep, or away from their desks, so it may take a while for your comment to appear. Eventually it will – unless it’s offensive or libelous (in which case it won’t.)