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

If Ally passed her licensing exam on Jan 15,2019 when should she complete her 30 hr Post Licensing course per Indiana guidelines?
What determines the stability of nucleus. explain?
Activity: Use a dictionary and fill in the empty boxes with the correct parts of speech for the given root words. Please note that some root words might not hav
1.Amina bought 112 toffees each at GH40.45p. She sold each at GH40.53p. Find the total amount she bought the toffees, correct to 2 decimal places received from
You borrow 600$ to buy a violin.simple annual interest rate is 15$ you pay off the loan after 2 years of equal monthly payment. How much is each payment
Briefly describe major sings childhood
A pencil is 712 inches long. How long is the pencil in centimeters?
Who was known as tiger of the north in the Mexican revolution
Whats the area of a parallelogram with a hight of 4cm and a base of 16cm
In Figure 1, ABCD is a rectangle with AB = 12 cm and BC= 7 cm. AK= BL= CM= DN = x cm. If the area of KLMN is 54 cm², find x.