yes
Time Limit: 1 seconds
Memory Limit: 1024 MB
Rating: 1000
Problem StatementI am thinking of 2 integers $A$ and $B$. The first integer given is the sum $(A+B)$ and the second is the difference $(A-B)$. Output the 2 numbers I'm thinking of on separate lines.
InputThe first line has the value of $A+B$. The second line has the value of $A-B$.
OutputOn the first line, output $A$. On the second line, output $B$. Note: Make sure that $A \le B$ when outputting, otherwise your solution may be marked incorrect.
Sample CasesSample Input 1: 3 1 Sample Output 1: 2 1Explanation
$2 + 1 = 3$ $2 - 1 = 1$
SourcesIanOJ Contest #2 (Div. 4) > Problem D2 (Contributed by bronze@HungJan@)
Submit | Back