Apple

  www.apple.com
Work in HR? Unlock Free Profile

Apple Software Engineer Interview Question

"Ants are at the corners of an equilateral triangle labelled 1, 2, and 3, each ant starts moving towards the next one (1 towards 2, 2 towards 3, 3 towards 1) at the same constant speed. How long until they meet ?"
Add Tags [?]
Answer

Part of a Software Engineer Interview Review - one of 2,299 Apple Interview Reviews

Answers & Comments

0
of 0
votes
I couldn't come up with a good answer, don't know if I am weak in geometry, calculus, logic, or just not smart enough.
- Interview Candidate on Jan 25, 2014
5
of 10
votes
Ants are never going to meet. because by the time 1 reaches 2 , 2 will reach 3 and 3 will reach 1. so they are never going to meet. :)
- Anonymous on Jan 26, 2014
0
of 0
votes
Here is the same problem but on a square rather than triangle: http://www.mytechinterviews.com/chasing-dogs
- Anonymous on Feb 8, 2014
1
of 1
vote
Here is the solution on youtube Three Ants - Solution https://www.youtube.com/watch?v=YCWgOsgPYBw
- Anonymous on Feb 8, 2014
2
of 2
votes
Also asked using Mice http://mathworld.wolfram.com/MiceProblem.html
- Anonymous on Feb 8, 2014
0
of 0
votes
The first inclination is to say that they'll never meet, because it's easy to consider the inside of the triangle off limits, but when answering a quest like this it's important to consider all of the possibilities. You should always ask questions like "Can the ants move on the inside of the triangle?" to get all of the available information. Here's one good example explaining how long and how far the ants would travel: https://www.youtube.com/watch?v=YCWgOsgPYBw
- Anonymous on Feb 21, 2014

To comment on this question, Sign In with Facebook or Sign Up

Tags are like keywords that help categorize interview questions that have something in common.