JavaScript – Distance

JavaScript – Distance

Write a JavaScript program that converts a distance in miles into a distance in meters. One
mile is equal to 1.60935 kilometers. If you multiply the number of miles times 1.60935, you will
calculate the number of kilometers. Declare miles as a variable and give it a value. Declare
kilometers as a variable. Use the formula above for converting miles to kilometers to assign a
value to kilometers. Display the results using document.write. Include the original number of miles and
the calculated distance in kilometers in the message displayed using document.write.
Personalize the page with your photo on the top.
FTP/Publish the file to the webpage.pace.edu server and submit the link on Blackboard