Skip to main content

Quick Probability Questions for Interviews


1) If cor(a,b)=0.5 and cor(a,c)=0.0, what is the range for cor(b,c)

2) A deck of pokers. Three choices: A: 26 black, 26 Red; B: 13 black, 13 Red; C: random 26 card from the deck. Take the first two cards, if same color, the win $1, otherwise lose $1. Which deck is best for you if you are playing? Why?

3) What is the probability of a random generator generating 10 consecutive numbers in ascending order (assume it is a perfect random generator)

Update (24/12/2012):
Solution posted by AH in comments! Solution explained in detail by me. Thanks

Comments

  1. 1) It will be like solving matrix
    [\sigma_a^2 0.5\sigma_a\sigma_b 0 \\
    0.5\sigma_a\sigma_b \sigma_b^2 cor(b,c)\sigma_a\sigma_b \\
    0 cor(b,c)\sigma_a\sigma_b \sigma_c^2]
    such that each row and column sum is 1

    Was not able to solve it completely

    2) 26B 26R Probability = 25/51
    13R13B 12/25
    26 random number
    Let x R and 26-x B cards are choosen
    Now x can be uniformly between 0 to 26
    Probability = \integral_{0}{26} (x(x-1)+(26-x)(25-x))/(26*25*26) dx
    Probability = 0.653
    Deck 3 is the best

    ReplyDelete
  2. 1.) Correlation matrix should be non negative definite => determinants at all levels should be >= 0 => x^2 < 3/4

    2.) Expected Winnings:
    Choice A: ((1)*(25/51)) + ((-1)*(26/51)) = -1/51
    Choice B: ((1)*(12/25)) + ((-1)*(13/25)) = -1/13
    Choice C: Same as A (Sampling 26 random cards and then taking the first two is same as just taking the first two from the whole deck)

    3.) 1/10!

    ReplyDelete
  3. @AH.. Thanks for the correct solutions to all the three problems.

    Q.1

    A more detailed solution of first question:
    The correlation matrix for a, b, c is as follows:
    first row as (1.0, 0.5, 0.0)
    second row as (0.5, 1.0, x)
    third row as (0.0, x, 1.0)

    has to be positive definite
    Hence, 1*(1-x^2) - 0.5*(0.5) >= 0
    Hence, x^2 < 0.75

    Q.2

    A more mathematical explanation for the Choice C of the second question is "Total Probability Theorem".

    ReplyDelete
    Replies
    1. Q1) why is variance of a, b, c =1

      Delete
    2. without loss of generality you can take mean=0 and variance=1. This is because correlation is invariant over location and scale transformations. Correlation between (x,y) =
      Correlation between ((x-a)/b , (y-c)/d)

      Delete

Post a Comment

Popular posts from this blog

Asking a girl out

This is not a puzzle. So, for those of you who follow this puzzle blog, please bear with me for just one post. Interesting Math in this article though :P

Most of my friends already read an article that I wrote more than an year back - "Speak Up"


Here, inspired by the movie, The Beautiful Mind, I give a mathematical analysis of asking a girl out. Nice time it is. Feb 10. No plans for Feb 14 and I am sure this article makes me look even more geekier and all the more reason for me to believe that I will be alone, yet again. But what the hell, lets do it!

Note: This is not an independent analysis. There are many "mathematics sites" which does "similar" analysis.

@Consultants, correct me if I am wrong in my estimates. :P

Why is there a need to be selective?

From the age of 15, I guess there are approximately 3,600 girls I have liked (On average days, I don't see new girls. But going outside, I like about 30 girls. Saying that I go out once every week right …

Consecutive Heads

Let's say A keep tossing a fair coin, until he get 2 consecutive heads, define X to be the number of tosses for this process; B keep tossing another fair coin, until he get 3 consecutive heads, define Y to be the number of the tosses for this process.

1) Calculate P{X>Y}
2) What's the expected value of X
3) What's the expected value of Y

This is probably the hardest puzzle I have ever put on my blog. Hence, I will post its solution in the post directly rather than on comment.

Solution:
1)
(Solved by me finally after 13 months :))

Make a state diagram. Let the state be (a,b) where a is the number of consecutive heads streak "A" is on currently and b is the number of consecutive heads streak "B" is on currently.

So, (0,3) (1,3) are final accepted states and (2,0) (2,1) (2,2) (2,3) are failure states. If you get tails, your contribution to the state reaches to "0"

f(State) = P(X>Y | "State" configuration initially)

f(0,0) = 1/4[f(…

Fraction Brainteaser

Source:
Sent to me by Gaurav Sinha

Problem:
Siddhant writes a Maths test and correctly answers 5 out of 6 Arithmetic questions and 20 out of 28 Geometry questions. In total, Siddhant scores 25 out of 34. 

Vaibhav writes another Maths test and correctly answers 20 out of 25 Arithmetic questions and 6 out of 9 Geometry questions. in total, Vaibhav scores 26 out of 34.

Note that
a) Vaibhav scores more than Siddhant
b) Siddhant score better than Vaibhav in both individual topics - 5/6 > 20/25 and 20/28 > 6/9

How is it possible?