Question: Hi, I'm having trouble with my javascript coding homework. I have several exercises I need to write a code for, and then submit all of

Hi, I'm having trouble with my javascript coding homework. I have several exercises I need to write a code for, and then submit all of them in one HTML document. When the exercises are in their own separate documents everything works fine. However after I tried to put them all in one document, the answers to each problem won't accurately display. I'm using buttons to display my solutions (i.e. enter a number in a box, press a button, and the solution shows up another box).

When they're all together if I try to type in anything in any of the boxes, the document acts as if I entered something in the last box, and instead will try to display the answer for the last exercise, which in this case would be 0 since I haven't actually entered anything in the last exercise. I've tried separating each exercise by using

tags, as well as

but nothing has worked. I'm new to coding so I'm lost on how to solve this. I've copied and pasted my code below.

lab 3

Exercise 1

Enter age:

Excercise 2

Enter Fahrenheit:

Exercise 3

Enter US Dollars

Exercise 4

Enter Diameter

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!