The output should be composed of lines, each corresponding to an input dataset (a, b, d). An output line should contain two nonnegative integers x and y separated by a space. They should satisfy the following three conditions.
1. You can measure dmg using x many amg weights and y many bmg weights.
2. The total number of weights (x + y) is the smallest among those pairs of nonnegative
integers satisfying the previous condition.
3. The total mass of weights (ax + by) is the smallest among those pairs of nonnegative
integers satisfying the previous two conditions.
No extra characters (e.g. extra spaces) should appear in the output.