Prompt the user for their weight in pounds on earth

Assignment Help Computer Engineering
Reference no: EM132218415

Question :

Write a script named MoonWeight.m that prompts the user for their weight in pounds on Earth and then displays their mass and how much they would weigh on the moon.

Use appropriately-named variables to represent masses, to represent the radius of the Moon, and for conversion factors.

Constants should be all-caps, e.g. MASS_OF_MOON  Assume 1 pound mass (lbm) = 0.454 kilograms.

Assume 1 pound mass exerts 1 pound force (lbf) of force at your location on Earth.

Use your script compute_gravitational_force to compute the gravitational forces.

Test case: Someone who weighs 132 lbf on Earth would weigh 21.86 lbf on the Moon, which has a mass of 7.34767309e22 kg and a radius of 1737400 m.

Output should be formatted to look like Your mass is 59.93 kg. You would weigh 21.86 lbs on the Moon.

Your script must be commented, including the header and help comments.

Reference no: EM132218415

Questions Cloud

Develop an international marketing plan : The assignment involves the development of an international marketing plan, which would help a firm exploit the market opportunity to sell products.
Write a do-while loop that continues to prompt a user : Write a do-while loop that continues to prompt a user to enter a number less than 100, until the entered number is actually less than 100.
Write response on prizm cluster and vals type : When I was a teenager, I lived in a suburban area just 20 minutes away from Center City, Philadelphia. The clusters that were listed were as follows.
Write the line that declare and creates a 2-d array of chars : Write the line that declare and creates a two-dimensional array of chars, tictactoe, with 3 rows, each with 3 elements , and initialize it to all space.
Prompt the user for their weight in pounds on earth : Prompt the user for their weight in pounds on Earth and then displays their mass and how much they would weigh on the moon.
Have the widest variety of interests and activities : I think I have a nice blend of attributes from both the primary and secondary VALS segment profiles. I placed asterisk next to the ones.
What is the latest version of html : What is a computer that manages shared resources for access across a network called?
Write an introduction and a mission statement for company : Need an introduction and a mission statement for this company I am opening up. A brief description of the company is attached (document labeled cafe by day bar)
Write a function that accepts a string : Write a function named word_count that accepts a string as its parameter and returns the number of words in the string.

Reviews

Write a Review

Computer Engineering Questions & Answers

  Mathematics in computing

Binary search tree, and postorder and preorder traversal Determine the shortest path in Graph

  Ict governance

ICT is defined as the term of Information and communication technologies, it is diverse set of technical tools and resources used by the government agencies to communicate and produce, circulate, store, and manage all information.

  Implementation of memory management

Assignment covers the following eight topics and explore the implementation of memory management, processes and threads.

  Realize business and organizational data storage

Realize business and organizational data storage and fast access times are much more important than they have ever been. Compare and contrast magnetic tapes, magnetic disks, optical discs

  What is the protocol overhead

What are the advantages of using a compiled language over an interpreted one? Under what circumstances would you select to use an interpreted language?

  Implementation of memory management

Paper describes about memory management. How memory is used in executing programs and its critical support for applications.

  Define open and closed loop control systems

Define open and closed loop cotrol systems.Explain difference between time varying and time invariant control system wth suitable example.

  Prepare a proposal to deploy windows server

Prepare a proposal to deploy Windows Server onto an existing network based on the provided scenario.

  Security policy document project

Analyze security requirements and develop a security policy

  Write a procedure that produces independent stack objects

Write a procedure (make-stack) that produces independent stack objects, using a message-passing style, e.g.

  Define a suitable functional unit

Define a suitable functional unit for a comparative study between two different types of paint.

  Calculate yield to maturity and bond prices

Calculate yield to maturity (YTM) and bond prices

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd