跳到主要内容
← 返回题库
免费智力题简单

Ants on a Triangle

考察公司Akuna CapitalIMC Trading

题目

Three ants sit at the three corners of an equilateral triangle. Each ant independently picks one of the two adjacent corners uniformly at random and walks along that edge.

What is the probability that no two ants collide? Generalise to nn ants on a regular nn-gon.

解析

先自己试一试,卡住了再打开提示。

查看解析

Each ant chooses clockwise or anticlockwise, so there are 23=82^3 = 8 equally likely configurations.

No collision happens only when the ants all travel in the same rotational direction — any mismatch means two ants either meet head-on along an edge or arrive at the same vertex. There are exactly 2 such configurations (all clockwise, all anticlockwise), so

P(no collision)=28=14.P(\text{no collision}) = \frac{2}{8} = \frac{1}{4}.

General nn-gon. The same argument applies: 2n2^n configurations, 2 of which are collision-free, giving

Pn=22n=21−n.P_n = \frac{2}{2^n} = 2^{1-n}.

Why it is asked. It is a 30-second problem that separates candidates who enumerate carefully from those who guess. The useful instinct is to characterise the good outcomes rather than count the bad ones.