# Trading associate Interview Questions

# 6K

Trading Associate interview questions shared by candidates### There are 1000 buckets, one of them contains poison, the rest are filled with water. They all look the same. If a pig drinks that poison it will die within in 30 mins. What is the minimum amount of pigs you need to figure out which bucket contains the poison.

14 Answers↳

I make it 10. The first pig drinks from every other bucket. The second pig drinks from the first two buckets, then skips two, and so forth. The tenth pig drinks from the first 512 buckets. Wait 30 minutes. You can determine which bucket is poisoned uniquely from the pattern of porcine mortality - if all the pigs die then then first bucket is poisoned. If none of the pigs die then the last bucket is poisoned (it's a binary encoding). You have 30 minutes to spare. You might think it possible to divide the problem up between these two halves, but since the experiment might kill all your pigs the worst case would be needing 9+9 = 18 pigs, so worse than doing it all in one shot. Less

↳

Matt has the right idea with the encoding, but 1 hour gives you time for two passes. So first you divide the 1000 buckets into groups of 32 buckets each. You'll have 32 groups (the last one with only 8 buckets). The 32 groups you can binary encode with 5 digits, so 5 pigs will tell you after 30 mins which _group_ of buckets contains the poisoned one. So for the the second 30 mins you binary encode that group of 32 buckets the way Matt described. This way you're using no more than 5 pigs at any given time. You might still kill a total of 10 in the worst case, but this approach takes advantage of the extra time to reduce the number of pigs used simultaneously. Slightly more efficient. Less

↳

I think the question is missing "within one hour?" at the end. If that's the case then you only get two tests / trials. Start with 33 pigs each drinking from 30 buckets, then wait 30 min. If none die, then it's the leftover bucket, if one dies then get another 30 pigs to drink from the buckets that the dead pig drank from. Less

### You are playing a game where the player gets to draw the number 1-100 out of hat, replace and redraw as many times as they want, with their final number being how many dollars they win from the game. Each "redraw" costs an extra $1. How much would you charge someone to play this game?

10 Answers↳

This is all very interesting and I'm sure has some application...but to trading? I don't think so. I own a seat on the futures exchange and was one of the largest derivatives traders on the floor. Math skills and reasoning are important but not to this level. I would associate day trading/scalping more to race car driving i.e. getting a feel for what's going on during the day, the speed at which the market is moving and the tempo for the up and down moves. If I were the interviewer at one of these firms, I throw a baseball at your head and see if you were quick enough and smart enough to duck. Then if you picked it up and threw it at my head I'd know that you had the balls to trade. I know guys who can answer these questions, work at major banks, have a team of quants working for them and call me up to borrow money from me because they're not making money. At the end of the day, if you want to be a trader then...be a trader. If you want to be a mathematician then be a mathematician. It's cool to multiply a string of numbers in your head, I can do this also, but never in my trading career did I make money because in an instant I could multiply 87*34 or answer Mensa questions which...realistically the above answer is: it depends on the market as the market will dictate the price. You may want to charge $87 to play that game but you'd have to be an idiot to play it. In trading terms this means that when AAPL is trading at $700 everyone would love to buy it at $400. Now that it's trading at $400 everyone is afraid that it's going to $0. Hope this helps. No offense to the math guys on this page, just want to set the trading record straight. Less

↳

All of the above answers are way off. For a correct answer, see Yuval Filmus' answer at StackExchange: http://math.stackexchange.com/questions/27524/fair-value-of-a-hat-drawing-game Less

↳

Let x be the expected value and n be the smallest number you'll stop the game at. Set up equation with x and n, get x in terms of n, take derivative to find n that maximizes x, plug in the ceiling (because n must be integer) and find maximum of x. ceiling ends up being 87, x is 87.357, so charge $87.36 or more Less

### What's the square root of 2000?

10 Answers↳

sqrt(2000) = sqrt(100 x 20) = 10 sqrt(20). sqrt(20) = sqrt(4 x 5) = 2 sqrt(5) I wouldn't be able to guess sqrt(5) very accurately other than it is greater than 2 and less than 3. sqrt(2000) = 44.7 (calculator), though 20 sqrt(5) would probably be good enough. Less

↳

If you can do a little multiplication and adding in your head this is not too difficult. First get a rough estimate about where you need to be. Try 40 x 40 = 1600. Good but you can do better. Try 44 x 44 = (44x40) + (44x4) = 1760 + 176 = 1936. Now try 45 x 44. All this is saying is we need 45 sets of 44. So take 1936 and add 44 to it. The result is 1980. Now try 45 x 45. All this is saying is that we need 45 sets of 45. Since we can reverse numbers in multiplication we already have 44 sets of 45 which is 1980. Just add 45 to 1980 and the result is 2025. So we know the square root is somewhere between 44 and 45. The range from 1936 to 2025 is 89. 2000 - 1936 = 64. So what is 64/89? Round it up so we get a fraction like 70/100 which is .7. Therefore, 44.7 is a good estimate. The actual root is 44.72135954.... Hope that helps. Less

↳

The square root of 2000 is a number that when multiplied by itself (once) is equal 2000 Less

### I have 10 cards face-down numbered 1 through 10. We play a game in which you choose a card and I give you the corresponding dollar amount. a) What is the fair price of this game? b) Now, after picking a card you can either take the dollar value on the card or $3.50. Also, cards worth less than 5 are now valued at $0. What is the maximum price you are now willing to pay for the game?

10 Answers↳

Total amount=3.5*4+(5+6+~+10) Expected value=total/10=5.9 @FJM no idea where your 4.5 coming from Less

↳

Agreed. I double counted. 3.5*.4 + 7.5*.6 3.5 was given 7.5 =(5+6+7+8+9+10)/6 Less

↳

"You decide on taking the dollar value on the card or $3.50 *before* seeing the number on the card." 2nd game: Obviously, the game price should be no less than 3.5, otherwise there is an opportunity for arbitrage. Now that the price is higher than 3.5, it makes no sense for a rational player to choose just take 3.5 dollar and exist the game. The player should always choose to bet. And the expectation for betting is (5+6+...+10)/10 = 4.5. Less

### Say I take a rubber band and randomly cut it into three pieces. What's the probability that one of the pieces has length greater than 1/2 of the original circumference of the rubber band.

9 Answers↳

The correct answer is 3/4, as this problem is equivalent to the famous 3-points-on-semicircle problem. Why? If one of the pieces has length greater than 1/2 the circumference, then the three points of cutting must lie in the same semicircle. On other hand, if the three points of cutting lie on the same semicircle, then the longest piece must be at least 1/2 of the circumference. Less

↳

For reference to the 3-points-on-same-semicircle problem, see e.g., http://godplaysdice.blogspot.com/2007/10/probabilities-on-circle.html Less

↳

This problem is also equivalent to the probability that, if you have a line segment from 0 to 1 and you make 2 random cuts on that line segment, what is the probability that the three resulting pieces do NOT make a triangle? Less

### You have three barrels. One barrel is filled with apples, one with oranges, and one with both apples and oranges. Each barrel is mislabeled. You can take out as many fruit as you like form each barrel and look at it. What is the minimum number of fruits you need to remove to correctly label the barrels?

8 Answers↳

One. Since it's mislabeled, A can be labeled as O or A+O. Similarily, O = {A, A+O} and A+O = {O, A}. Case 1: Take 1 from A+O label, it turns out to be A. Relabel it. We have A, O mislabels left, and A+O, O real labels left. Mislabeled ones can ot be the same as real labels. So the mislabeled O should be A+O and A should be O. Case 2: also choose from A+O, but it turns out to be O. Solving the same as case 1. Less

↳

None, you don't need to move any of the fruit to correctly label the barrels. You need to change the labels. Less

↳

All three are mislabeled and you cannot look inside the barrels. If you take one out of the apples+oranges barrel, whatever fruit you pull out is the fruit of the barrel. And Since you know the other two are mislabeled, you would switch the labels. So you need to take out only one fruit Less

### Game1 : a dice roll with a 100-faces dice, labeled from 1 to 100. 1. You get to roll once and receive the amount of dollars labeled on the face, how much would you like to pay for this roll. 2. How much would you pay if you can roll the dice twice if you are unsatisfied with the first outcome? 3. You can roll the dice infinite times, and costs 1 dollar for each roll except the first one. What is your strategy? Game2: you are competing in a game with 2 other players. with a 21-faces dice (labeled 1-21). All three of you gets to choose a number and then roll the dice. Whoever chose the number closest to the outcome wins. What is your strategy? another twist: what if all three of you can communicated?

8 Answers↳

3. This is hard but you have 7 rolls on average to get a number in the top 7th (ie 86+) and the number averages a 93 1/7 . You spend 7 rolls so your expected is 86 1/7 Less

↳

the infinite roll approaches the expectation of profit to be 86.3571 please run the following matlab code i wrote % this calculate the expecation of the profit when you throw a 100-faced % dice - given the value of the accepted tossed points - the first toss is % free - starting from the 2nd toss you pay 1£ to play again % input: Nmax -- the largest max number of tosses allowed % output: % N -- number of maximum allowed tosses % P -- expectation of the profit function [N, P] = one_hundred_faced_dice(Nmax) N = linspace(1, Nmax, Nmax); P = N - N; %---if we only throw it once, the expectation is 50.5 P(1) = 50.5; %---throw more times-- P(i-1) is known for i = 2:Nmax, %----if the first toss is lower than N(i-1), toss it again P(i) = floor(P(i-1))*P(i-1)/100; %----if the first toss is higher than N(i-1), accept it for j = (floor(P(i-1))+1):100, P(i) = P(i) + 0.01*j; end %----however from the 2nd toss, we need to pay to play it P(i) = P(i) - 1; end %----draw the curve plot(N, P); end Less

↳

if you are going to roll an M-faced dice for Nmax times with a fee starting from the 2nd roll please run the following matlab code % this calculate the expecation of the profit when you throw a 100-faced % dice - given the value of the accepted tossed points - the first toss is % free - starting from the 2nd toss you pay 1£ to play again % input: Nmax -- the largest max number of tosses allowed % M -- no. of faces % output: % N -- number of maximum allowed tosses % P -- expectation of the profit function [N, P] = M_faced_dice(Nmax,M,fee) N = linspace(1, Nmax, Nmax); P = N - N; %---if we only throw it once, the expectation is 50.5 P(1) = (1+M)/2; P(1) = P(1) -1; %---throw more times-- P(i-1) is known for i = 2:Nmax, %----if the first toss is lower than N(i-1), toss it again P(i) = floor(P(i-1))*P(i-1)/M; %----if the first toss is higher than N(i-1), accept it for j = (floor(P(i-1))+1):M, P(i) = P(i) + j/M; end %----however from the 2nd toss, we need to pay to play it P(i) = P(i) - fee; end %----draw the curve plot(N, P,'o-'); end Less

### Flip a coin. if head, I win 1 point. If tail, u win 1 point. The person who first wins 2 points wins the game. And the loser must pay winner $1. However, if I have a option which I can increase the stake of the game to $2/game, what is the value of such option.

8 Answers↳

Anonymous is right but the option is going to be used for 2/3 times. expected gain with option is 2/3(1) + 1/3(-1) = 1/3. expected gain without option is 0. the value of the option is then 1/3. Less

↳

dont believe above answer is correct: as correctly mentioned, this option would only be used if you are 1-0 up. Of the next 2 coin flips for (assuming i want heads), after the 1-0 scenario is HH, HT, TH, TT. Of which, all but 1 will give me $2. So $2 x 0.75 = $1.5 in. compared to $-2 x 0.25 = -$0.5 averaging out the above gives you +$1 expected value. Going further (i.e. what is this option worth to you before the game starts), you start off 0-0, you wouldnt use it. you go 1 down, you wouldnt use it, you go 1 up you do use it. It will only be used in 50% of scenarios, therefore you pay no more than $0.5 for it. Less

↳

option is worth 0.25 at time 0. at time 1 (after one flip) the option is worth zero or 0.5 (as mentioned above) depending on whether it will be exercised. draw out a tree and this can be clearly seen Less

### I have 20% chance to have cavity gene. If I do have the gene, there is 51% chance that I will have at least one cavity over 1 year. If I don’t have the gene, there is 19% chance that I will have at least one cavity over 1 year. Given that I have a cavity in 6 months, what’s the probability that I have at least a cavity over 1 year?

7 Answers↳

You can use the Bayes theorem to calculate the posterior probability of having the cavity gene. P(gene | cavity 1) = P( cavity | gene) * P( gene) / P(cavity) = 2/5 (rounding off all the probabilities) Now, using the posterior probability, you can calculate the revised probability of having a cavity P( cavity 2 | cavity 1) = P( cavity 2 | gene) * P( gene | cavity 1) + P( cavity 2 | no gene) * P( no gene | cavity 1) = 8/25 Less

↳

I also got 229/700

↳

First calculate p(G | C in 6 M) = p(C in 6 M| G) p(G) /( p(C in 6 M| G)p(G) + p(C in 6 M | !G) p(!G) ) = 3/7 Now p(C in 1 Y| C in 6 M) = 0.51 * 3/7 + 0.19 * 4/7 = 2.39/7 Less

### You begin with $100. You flip a fair coin. Heads, you get 1$. Tails, your money gets inversed (i.e. first tails, your money is now 1/100). What is the expected value after 7 flips? (hint: recursion)

7 Answers↳

You're on the right path, but I think I have a slightly more intuitive way of looking at it: As the person before me mentioned it's much easier to simplify this problem by finding the probability that you end near 100. There are two ways to end near 100, you either already have 100 and flip heads, or you have 100 and flip tails twice in a row, everything else will give you a messy fraction. Let's see how this plays out: Flip 0: you have one 100. Flip 1: the 100 becomes 101, you still have one. Flip 2: the 101 becomes 102, the 100 from flip 0 has now flipped back and gave us 100, now we have two. Flip 3: the 102 becomes 103, the 100 becomes 101, and the 101 from flip 1 flipped back and gave us 101, now we have three. A familiar pattern is emerging. You can add the number of 100s from the turn before and the number of 100s from two turns before (the flip backs) to determine how many 100s you have now. The sequence will goes 1, 1, 2, 3, 5, 8, 13, 21. Fibonacci! It's not a perfect answer, but for aesthetic purposes i will go with 21/128. Less

↳

@the one before me (again) Aren't the bounds 107 (highest) and 1/106(lowest)?

↳

@ones after: no yes and yes. 49 is incorrect. The correct divisor is 2^7. That was my mistake. As for the second question, I was being pretty fast and loose with my rounding. The point is only that there is a similar probability of both values near 0 and near 100, so the value ought to be between. I believe I messed up the 49 Less