In: Computer Science
Write a Pearson Module pseudocode that asks the user to enter an object’s mass in kgs, and then calculate its weight. If the object weighs more than 1000 Newtons, display a message indicating that is too heavy. Otherwise display a message indicating that the object is light. Test your code in Flowgorithm. Given: Weight = Mass * 9.8 (where mass is in kilograms)
Hi,
Please find the answer below:
-------------------------------
Pseudocode:
Function Main
Declare Real Mass, Weight
Display "Enter object mass in Kgs: "
Input mass
Set Weight = Mass * 9.8
If Weight > 1000 Then
Display "The object is too heavy."
Else
Display "The object is light."
End If
End Function
Flowchart Screenshot:
Test Code:
To run the flowchart click on the green arrow button.
-------------------------------
Hope this helps.
Let me know if you need more help with this.
Kindly, like the solution if you find it useful
Thanks.