Interview Question: Itsy Bitsy Spider

Sample Question #298 (probability theory)
 
A spider must eat three flies a day to survive. (It doesn’t need to eat more than three.) The spider has a 50% chance of catching any fly that comes near its web. What are the spider’s chances of survival, given that five flies have already come near its web today?
 
[A classic; you may see variants of this question featuring other predators and preys]
Advertisements
This entry was posted in Sample Qs. Bookmark the permalink.

One Response to Interview Question: Itsy Bitsy Spider

  1. Brett says:

    ANSWER
     
    The key is to recognize that the probability is a binomial distribution.
     
    The spider’s chance of survival is therefore Pr(>=3 flies)*1 + Pr(<3 flies)*0.5 = Pr(=3 flies)*1 = Pr(<3 flies)*0.5 [since once it eats 3 flies, its survial probability is 100%] where Pr() is a binomial(5, 0.5) distribution. The final answer is 0.75.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s