I recently came across the following question.
Given a matrix representing which child likes which toy. matrix[i][j]=1 represents that child i likes toy j. One child can get only 1 toy and one toy can be assigned to only 1 child.Find maximum number of children who can get the toy they wished.
One approach i can think of is going through all possible ways of distributing the toys but it wont work if the constraints are high, what can be a better approach.