Function to compute the largest possible number of people in a tower such that each person is shorter and lighter than the person below him or her