The vile invaders did not like that they killed very few people in the village of Mega Brains, and so they decided to complicate the task, they also took 100 Mega Brains, put them in a column one after another, so that each previous one sees all the subsequent ones. But this time they took caps of seven colors (red, orange, yellow, green, blue, blue, violet), put them on Mega Brains, so that every MegMind does not see its cap. Starting from the very last (the one who sees everyone but himself), each MegaMann is asked to ask the color of his hat, if he makes a mistake, they kill him. But as always, Mega Brains agreed in advance how to minimize the number of dead. What did Mega Brains agree on?
Source: https://habr.com/ru/post/15556/
All Articles