Answers for "1038 solution python"

0

1038 solution python

X,Y=list(map(int,input().split()))
if(X == 1):
    price  = (float) (4.00 * Y)
elif(X == 2):
    price  = (float) (4.50 * Y)
elif(X == 3):
    price  = (float) (5.00 * Y)
elif (X == 4):
    price  = (float) (2.00 * Y);
elif (X == 5):
    price  = (float) (1.50 * Y)
print(f"Total: R$ {price:.2f}")
Posted by: Guest on July-23-2021
0

1036 solution python

import math
A,B,C = map(float,input().split())
D = (B**2)-(4*A*C)
if(D <0 or A==0):
    print("Impossivel calcular")
else:
    D=math.sqrt(D)
    R1 = (-B+D)/(2*A)
    R2 = (-B-D)/(2*A)
    print(f'R1 = {R1:0.5f}\nR2 = {R2:0.5f}')
Posted by: Guest on July-23-2021
0

1038 solution python

X,Y = map(int,input().split())
Item = {1:4.0,2:4.5,3:5.0,4:2.0,5:1.5}
X = float(Item[X])*Y
print(f"Total: R$ {X:.2f}")
Posted by: Guest on February-15-2021

Python Answers by Framework

Browse Popular Code Answers by Language