Write a program to convert a U.S. Customary System length in miles, yards, feet, and inches to a Metric System length in

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899603
Joined: Mon Aug 02, 2021 8:13 am

Write a program to convert a U.S. Customary System length in miles, yards, feet, and inches to a Metric System length in

Post by answerhappygod »

Write A Program To Convert A U S Customary System Length In Miles Yards Feet And Inches To A Metric System Length In 1
Write A Program To Convert A U S Customary System Length In Miles Yards Feet And Inches To A Metric System Length In 1 (111.41 KiB) Viewed 29 times
Write a program to convert a U.S. Customary System length in miles, yards, feet, and inches to a Metric System length in kilometers, meters, and centimeters. A Sample run is shown below. After the number of miles, yards, feet, and inches are read from the text boxes, the length should be converted entirely to inches and then divided by 39.37 to obtain the value in meters. The Int function should be used. to break the total number of meters into a whole number of kilometers and meters. The number of centimeters should be displayed to one decimal place. Use the naming convention provided for all controls on the form and all variables used. The needed formulas are as follows: dblTotal inches = (63360 intMiles) + (36 int Yards) + (12 * intFeet) + intInches dblTotal_meters = dblTotal inches / 39.37 intKilometers = Int (db1Total_meters/1000) Shown at Start up: Project1: Length Conversion Miles: 0 Yards: 0 Feet: 0 Inches: 0 0 Convert To Metric Miles: 5 Yards: 20 Feet: 2 Inches: 4 Shown after entering data and clicking on button: Project1: Length Conversion Convert To Metric -OX The Metric Length is 8 kilometers, 65 meters, 73.5 centimeters. _OX
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply