AceTheInterview
Jobs in Pune | Work better in teams | Socialize with friends | Submit Q&A | Tell a friend
Search site for 

Top 100 Interview Questions & Answers in a convenient and easy to read book!

“I bought this guide a few days ago to prepare for my interview with Oracle. Many of the questions they asked me were from this guide. I found this book absolutely great!”

– Ravi, California

Read more comments...

Interview Questions And Answers RSS Feed

Answers »

  1. Submitted By: subba — October 10, 2006
    +51 votes
      + -

    0.25
    explanation:
    there are 2^3 ways
    only 2 ways are possible without colliding.

    so 2 out of 8 ways.

  2. Submitted By: Sameer — February 5, 2007
    -19 votes
      + -

    Well the probability they WON’T collide is 3/4 i.e. 0.75

    These things would matter I suppose.

  3. Submitted By: Tushar Agrawal — March 10, 2007
    +8 votes
      + -

    subba is right..

    another way to solve it:
    1st ant can take any direction. assuming it started moving towards ant 2.
    probability tht 2nd ant will collide with 1st one = 1/2
    in case 2nd ant doesnt collide with the 1st one, probability tht 3rd ant will collide with 2nd = 1/2*1/2
    probability tht 3rd ant will collide with 1st one = 0

    so probability tht 2 ants collide = 1/2+1/4 = 3/4
    hence, probability tht there is no collision = 1-3/4 = 1/4

  4. Submitted By: mmm — March 22, 2007
    +4 votes
      + -

    let’s take it math:
    the set of all possibilities is the set of all 3 digit binary numbers (000, …, 111) => 2^3=8

    define not collide: any 2 digits are equal => 000 and 111 => 2 posibilities

    so the probability is 2/8% = 25%

  5. Submitted By: Bala Sethuraman — April 4, 2007
    +3 votes
      + -

    My explanation

    suppose 3 ants named a, b, c

    prob of colliding is
    = a and b moving towards each other + b and c moving towards each other + c and a moving towards each other
    = (1/2)* (1/2) + (1/2)* (1/2) + (1/2)* (1/2) = 3/4

    therefore, prob of not colliding = 1- 3/4 = 1/4

  6. Submitted By: mkn — May 26, 2007
    -7 votes
      + -

    name the ants at corners - a1, a2 and a3

    a1 –> a2, a2 –> a3, a3 –> a1 ==> o.k.

    a1 –> a2, a2 –> a1, a3 –> a1 ==> collide

    a1 –> a2, a2 –> a1, a3 –> a2 ==> collide

    similar for other cases

    so the possiblities for collision = 2/3 = 66%

  7. Submitted By: Swapnil Dipankar — August 16, 2007
    +3 votes
      + -

    Another way to look at it is in binary terms. Assume that if the ant moves in clockwise, we represent it by 1, 0 otherwise. The possible combinations are:

    0 0 0 - will not collide
    0 0 1 - collide
    0 1 0 - collide
    0 1 1 - collide
    1 0 0 - collide
    1 0 1 - collide
    1 1 0 - collide
    1 1 1 - will not collide

    that makes it 2/8 cases where there will be no collision… so probability will be 1/4… generalizing it, for ‘n’ ants on ‘n’ sides, the probability will be 2/(2^n) or 1/(2^(n-1))…

  8. Submitted By: zman — September 21, 2007
    not yet rated
      + -

    Ants would stop to communicate with each other unless they each headed in the same direction, i.e. clockwise or counterclockwise.

    That happens 25% of the time which is what others have said.

  9. Submitted By: kirby — January 9, 2008
    -1 votes
      + -

    There are 180 degrees in the triangle.

    To take a degenerate case, we assume that the triangle is an equilateral triangle. So, each corner has 60 degrees.

    This means, other than 60 and 0 degrees there is a possibility that they can crash. (Since random, we can assume all possibilities)

    Therefore, for each angle, there are 58 degrees for which other angles that can intersect.

    Hence, 180 - 6 = 174 degrees that will intersect.

    Or 174/180 is the answer for which the ants can collide. Hence it’s only 6/180 or 1/30 for which the ants will not collide.

    I’ve got 3 oz of grand marnier in my system. If I’m wrong, I blame it on the french!

  10. Submitted By: thorton — May 13, 2008
    not yet rated
      + -

    Assuming the ants go in a straight line; Ants won’t collide as long as they all go the same direction.

    1st and goes to a corner (doesn’t matter which).
    probability that the 2nd ant goes in the same direction (1/2)
    probability that the 3rd ant goes in the same direction as the first two (1/2).

    Probability they are all going in the same direction (won’t collide) (1/4)

  11. Leave an Answer/Comment

    To prove you're a person (not a spam script), type the security text shown in the picture. Click here to regenerate some new text.
    Click to hear an audio file of the anti-spam word

Our Sponsors
Our Sponsors
Contact Us | FAQ | Sitemap | Terms of Use | Privacy Policy | Tell a Friend

Copyright © 1999-2006 Jeeve Technologies LLC. All rights reserved.