Question: Using Thonny for the following Question: Table 5.5 contains some lengths in terms of feet. Write a program that displays the nine different units of
Using Thonny for the following Question:
Table 5.5 contains some lengths in terms of feet. Write a program that displays the nine different units of measure; requests the unit to convert from, the unit to convert to, and the quantity to be converted; and then displays the converted quantity. A typical outcome is shown in Fig. 5.47. Use the file Units.txt to create a dictionary that provides the number of feet for a given unit of length. The first two lines of the file areinches,.083333; furlongs,660.
TABLE 5.5 Equivalent lengths. 1 inch = .083333 foot 1 yard = 3 feet 1 meter = 3.28155 feet fathom 6 feet 1 rod= 16.5 feet 1 furlong = 660 feet 1 kilometer= 3281.5 feet 1 mile5280 feet UNITS OF LENGTH inches rods meters furlongs miles kilometers yards fathoms feet Units to convert from: yards Units to convert to: miles Enter length in yards: 555 Length in miles: 0.3153 FIGURE 5.47 Possible outcome of Programming Project 1
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
