We've been dealing with integers too much, it's time for decimals to shine!
Instructions:
Input
A line containing five decimal numbers separated by a space.
1.1·1.2·1.3·1.4·1.1
Output
The first line contains all the inputted decimal numbers separated by a space.
The second line contains a string which is the result.
1.1·1.2·1.3·1.4·1.1
Yes
arr = map(float, input().split())
if len(arr) != 5 or arr[0]+arr[1]+arr[2]+arr[3]<=arr[4]:
print('No')
else:
print(*arr)
print('Yes')
Comments
Leave a comment