Answer:
127
Explanation:
You want the minimum number of flips of a coin in a group of 8 coins that will ensure one of the permutations has all coins with the same side.
Permutations
There are 2⁸ = 256 permutations of heads and tails among 8 coins. Half that number, 128, will ensure that 7 of the coins will match the 8th one.
The least number of flips to get from one permutation to another is 1, so 128 -1 = 127 coin flips are necessary to ensure that 7 coins will match the 8th one at some point in the sequence.
127 coin flips are required.
__
Additional comment
Suppose we have 3 coins randomly arranged as HTH.
Leaving the first coin alone, it is sufficient to put the last two in every remaining permutation:
HTT, HHT, HHH . . . . result of 3 flips: coin 3, coin 2, coin 3 again
<95141404393>