Problem:-
Raghav is currently watching Netflix. He is feeling thrilled after watching Seasons 1, 2 and 3 of 13 Reasons Why, and is desperately waiting for release of Season 4. But the makers of the show are in no mood to release the next season anytime soon.
The makers of 13 Reasons Why give Raghav a challenge to solve. If he solves this challenge, then they will give exclusive copy of Season 4 to him.
But Raghav is feeling lazy. Can you help him solve this challenge?
Given 3 integers A, B, C. Do the following steps-
- Swap A and B.
- Multiply A by C.
- Add C to B.
- Output new values of A and B.
Explanation
Steps-
- After swap, A = 5 and B = 13.
- A is multiplied by 2. So, A = 10.
- 2 is added to B. So, B = 15.
Time Limit:1.0 sec(s) for each input file.
Memory Limit:256 MB
Source Limit:1024 KB
Solution:-
a,b,c=input().split()
a=int(a)
b=int(b)
c=int(c)
a,b=b,a
print(a*c,b+c)
0 Comments