#B4008. Restoring the True Attributes
Restoring the True Attributes
Restoring the True Attributes
In Little A's kingdom, there are three attributes whose sum is exactly \(10000\). However, the values observed by Little A are not the true attributes. Instead, he sees the following:
- The first attribute is shown after being multiplied by \(10\).
- The second attribute is shown after being divided by \(10\).
- The third attribute is hidden.
Let the true values of the three attributes be \(a\), \(b\), and \(c\) respectively. Based on the observations:
\[ \begin{aligned} 10a &= \text{observed first value},\\ a/\, \text{?} &\quad \text{(Note: See below)} \\ 0.1b &= \text{observed second value}. \end{aligned} \]Actually, the transformations are as follows:
- Observed first value \(A' = 10 \times a\) → \(a = A'/10\).
- Observed second value \(B' = b/10\) → \(b = B' \times 10\).
Since \(a + b + c = 10000\), the hidden third attribute is computed as \(c = 10000 - a - b\). Given the observed values \(A'\) and \(B'\), compute the true values of \(a\), \(b\), and \(c\).
inputFormat
The input consists of two numbers separated by spaces:
- The first number represents the observed value of the first attribute \(A'\) (which is \(10 \times a\)).
- The second number represents the observed value of the second attribute \(B'\) (which is \(b/10\)).
outputFormat
Output the three true attribute values \(a\), \(b\), and \(c\) separated by a space. Make sure the values satisfy \(a + b + c = 10000\).
sample
1000 200
100 2000 7900