Use sub-program
Execution time limit is 0.5 seconds
Runtime memory usage limit is 64 megabytes
Calculate the sum and product N pairs which set material numbers, having taken advantage of subroutine SumDob for calculation of the sum and product of two material numbers.
Input
In the first line set the natural number N - quantity of pairs numbers. In the subsequent N lines through a blank it set on 2 material numbers. All input on the module does not exceed 100.
Output
In N lines deduce through a blank on two numbers: at first the sum, and then product of the next pair numbers. Result deduces with accuracy 4 signs after a decimal point.
Examples
Input #1
Answer #1
Submissions 11K
Acceptance rate 49%