Question: Write a MIPS program that calculates bmi. Use the following C++ code as PSEDUOCODE. The variable bmi can be single or double precision. Please do

Write a MIPS program that calculates bmi. Use the following C++ code as PSEDUOCODE. The variable bmi can be single or double precision.

Write a MIPS program that calculates bmi. Use the following C++ code

Please do not repost answers to previous questions as they have been incorrect. Also, please comment your code. Thank you.

#include #include 3 using namespace std 5 int main ) int height = 0, weight = 0; double bmi; string name: 10 // Prompt user for their data cout name 12 13 14 15 16 17 18 19 20 21 cout >height: cout > weight: // Calculate the bmi weight *= 703; height *= height; bmi-static cast (weight) height: 23 24 25 26 27 28 29 // output the results cout

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!