Two people are within "shouting distance" if one can hear the other one shout.
We have a group of identical people located across the countryside.
We want to know how small the shouting distance can be and still allow a message to
originate with anyone and be heard by everyone else by a sequence of shouts.
The locations of the people are given by int[]'s x and y, with the location
of the i-th person given by the i-th element of x and the i-th element of y.
Create a class Shouting that contains a method shout that is given
x and y and that returns the smallest
shouting distance that will allow complete communication.
|