Ask Question
8 January, 14:27

2.3 Code Practice: Question 2

Write a program that inputs the length of two pieces of fabric in feet and inches (as whole numbers) and prints the total

+2
Answers (1)
  1. 8 January, 17:32
    0
    feetFab1 = int (input (""Enter the value in feet for the 1st piece of fabric: ""))

    inchFab1 = int (input (""Enter the value in inches for the 1st piece of fabric: ""))

    feetFab2 = int (input (""Enter the value in feet for the 2nd piece of fabric: ""))

    inchFab2 = int (input (""Enter the value in inches for the 2nd piece of fabric: ""))

    feetSum = (feetFab1 + feetFab2)

    inchSum = (inchFab1 + inchFab2)

    totalFeet = ((inchSum % 12) + feetSum)

    totalInch = (feetSum % 12)

    print (""Feet: "" + str (totalFeet) + "". Inches: "" + str (totalInch))
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “2.3 Code Practice: Question 2 Write a program that inputs the length of two pieces of fabric in feet and inches (as whole numbers) and ...” in 📙 Computers & Technology if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers