kittycarmona04 kittycarmona04
  • 03-11-2020
  • Computers and Technology
contestada

Assume: itemCost = input(“Enter cost of item: “) Write one line of code that calculates the cost of 15 items and stores the result in the variable totalCost

Respuesta :

Cytokine
Cytokine Cytokine
  • 03-11-2020

itemCost = input("Enter cost of items: ")

totalCost = 15 * float(itemCost)

print(totalCost)

The first line gets the total cost of the item from the user. The second line calculates the cost of 15 of those items and stores that value in the variable totalCost. The last line is just to test that our calculation works. I hope this helps!

Answer Link

Otras preguntas

what did the Muslims gain from the crusaders ?
Who was the first person to walk in the moon
How many cups are in 1 gallon of water
A picture frame for a square picture has an area of 80 square inches. What is the length of the picture?
2*10^30/1.4*10^27 and round it to the nearest tenth
2+3=8, 3+7=27, 4+5=32, 5+8=60, 6+7=72, 7+8=???????? SOLVE IT IF YOU CAN
The frequency of violet light is 7.5x10 to the 14th power hertz. What is the wavelength?
deer : woods : : monkey :
A merry-go-round makes 18 rotations in 3 minutes. What is its angular speed in rpm?
how many yards in a mile?