The number of people who went to the movies is X
Half went to a restaurant -> X/2
Of those who did not go to the restaurant (X/2) -> half went for a walk (X/4) + 4 returned to their houses. There were 5 left
with that information, we can write the following equation:
now, we just need to solve for x, as follows
in conclusion, 36 people went to the movies