Subjects

For Lab 9 I decided to implement a very VERY basic data-binding method. This means you can set the number of subjects using number field below, this will create an appropriate number of fields to enter the subject name and result, or use the + button to append more subjects.

As you change the result of a subject, both the average result (e.g. 55%) at the bottom, and each subject's grade (e.g. 'C') will be updated in real time to reflect your changes.

While this doesn't explicitly "ask a user how many subjects they take" using a prompt(), and show a typical prompt to "output the result" using an alert() it does use an array (of objects) to store the results, and then use the array to constantly re-construct the HTML and to calculate the average result.
Number of Subjects:
Average Result: