#164. 列表元素简单计算与格式化输出
列表元素简单计算与格式化输出
List Element Processing
Background
Congcong is doing a math exercise. He has received a set of numbers and needs to perform a specific calculation on each number.
Problem Description
Given a list of integers, return a new list where each integer is first added to , and then the result is multiplied by .
Input Format
Input is given from standard input in the following format.
A single line containing multiple integers, separated by spaces.
Output Format
Output is printed to standard output in the following format.
A single line containing the processed list of integers, in the format
[a, b, c, ...], where elements are separated by commas and spaces.
Sample
1 2 3
[20, 30, 40]
6 8 6 8 1
[70, 90, 70, 90, 20]
10
[110]
Sample Explanation
For the first sample, the input list is 1 2 3.
- For , calculate .
- For , calculate .
- For , calculate .
The final list is
[20, 30, 40].
Constraints
Time limit: second per test case. Memory limit: KiB per test case.