Question: Create an online mini calculator that can do addition, subtraction, multiplication and division. Each task should have two text boxes and a button. When a

Create an online mini calculator that can do addition, subtraction, multiplication and division.
Each task should have two text boxes and a button. When a button is clicked, the program will
perform a relevant task and result will be displayed under the button. This is an extension to the
in-class exercise (where only addition is demonstrated).
Rubric
1. You web page has a meaningful HTML title
2. Your web page has a header, instructions, labels, and required objects.
3. Your web page is well-structured.
4. HTML codes should be separated with JavaScript codes.
5. Each button click triggers a function call and the function is defined in the JavaScript file.
6. Results are displayed under the button and must be correct.
7. Handle divide-by-0 case. Use if/else statements to make sure the second textbox entry is
not 0. If it is 0, user should see an error message, otherwise, user will see the result.
8. Good HTML coding structures (e.g. good indentations, correct HTML tags)
9. Submit both HTML and JavaScript file. Your html file name must be in the format of
yourFullNameAssignment4.html. There is no requirement for the JavaScript file name.

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 Programming Questions!