37. The total capacity of three water buckets $A$, $B$, and $C$ is 1440 liters. If buckets $A$ and $B$ are full of water and bucket $C$ is empty; if all the water from bucket $A$ and $\frac{1}{5}$ of the water from bucket $B$, or all the water from bucket $B$ and $\frac{1}{3}$ of the water from bucket $A$ is poured into bucket $C$, bucket $C$ is exactly full. The capacities of buckets $A$, $B$, and $C$ are $\qquad$ liters, $\qquad$ liters, and $\qquad$ liters.
Answer: $480,400,560$