Starting from:

$25

ITIS/ITCS5180-Assignment 2 BMI Calculator Solved

Today we are building our first Android application. The app is a Body Mass Index (BMI) calculator. To calculate the BMI follow the below equation. The standard weight status categories associated with BMI ranges for adults (18 years and above) are shown in the following table.

Category
BMI
Underweight
BMI < 18.5
Normal or Healthy Weight
18.5 ≤ BMI < 25
Overweight
25 ≤ BMI < 30
Obese
30 ≤ BMI
 BMI = 703× hmeaigshst(2p(oinucnhdess))

BMI Calculator  

This is a single Activity application, as shown in Figure 1. The app requirements are as follows:

1.       The app enables the user to calculate their BMI based on the values provided in the the Weight and Height EditTexts. The BMI should be calculated based on the equation provided above.

2.      Clicking the “Calculate” button:

a)     If the age or weight or height are not entered correctly, display a toast indicating that this field is required.

b)     If the age is less than 18, display a Toast message indicating that the age should be 18 and above.

c)      If all the values are entered correctly, calculate the BMI value based on the provided equation and display the feedback as presented in the Figures 2(a) to 2(c). Notice the color differences in the presented cases.  

                                                                                    Figure 1, App Wireframe

More products