On the party, every boy gave $1$ candy to every girl, and every girl gave $1$ candy to every boy. Then, every boy ate $2$ candies, and every girl ate $3$ candies. It is known that $\frac{1}{4}$ of all candies were eaten. Find the greatest possible number of children at the party.

Let's think step by step and output the final answer within \boxed{}.
user