Question
Write a script that will calculate a persons weight on each planet of the solar system, the sun, and the moon. You should create an
Write a script that will calculate a persons weight on each planet of the solar system, the sun, and the moon. You should create an html form with text boxes for each planet (also the sun and moon). You should also have a text box for a person to enter their weight on Earth. When the user clicks on a button, a javascript function should be called that calculates each weight and puts the results in the corresponding text boxes in the form. Use the Math.round method to round the numbers to the nearest whole number. Here are some formulas for the conversions. Mercury= weight * .378 Venus = weight * .907 Mars = weight * .377 Jupiter = weight * 2.364 Saturn = weight * .916 Uranus = weight * .889 Neptune = weight * 1.125 Pluto = weight * .067 Sun = weight * 27.072 Moon = weight * .166
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started