You are in a dark room where a table is kept. There are 50 coins placed on the table, out of which 10 coins are showing tails and 40 coins are showing heads. The task is to divide this set of 50 coins into 2 groups (not necessarily same size) such that both groups have same number of coins showing the tails.
Keep a stack of 10 coins aside and rest 40 in stack 2 , and then reverse each coin in first group and keep the other group as same. And we get our solution.
Why this works?
10 coins= tails
suppose x tail coins go in group one then tail coins in group two is 10-x. when we reverse the first group, no. of tails become 10-x.