b. Execute: Output the perimeter of the rectangle to servlet. (1.0 point)
Question 2:
(3.0 points)
You are given a NetBeans template project (read more detail in the first page).
Your tasks:
• Add MyExam.jsp and start running from this page (As shown in figure 1) (The user can access
your page via url/MyExam.jsp): (0.5 point)
Enter height:
Enter weight:
cm
kg
BMI
Body Mass Index (BMI):
Height Weight BMI Conclude
Figure 1. Interface of page
(When the web page runs, if the interface is not the same as above, will not be considered for grading)
Assume users fill the integers for the textfields (called as height, weight), when users click
"BMI" button:
a. Check input for height and weight: If user input the height/weight that are integers <10, show
the error text "Height/Weight must be an integer>=10". (1.0 point)
When input height and weight
After pressing the "BMI" button
cm
Enter height: 9
cm
Enter height: 9
Zoom
+ 85%
Close