CSD 360 - JS Functions

Mod 8 Assignment

This assignment utilizes JavaScript functions to generate table data for display. Two functions are used to display the data. The first displays the square root, square, and cube of numbers 4 - 14. The second generates a multiplication table based on user input, displaying the products of the numbers within the input range. The first function used loop iteration to calculate the square root, square, and cube of the numbers. Then the values are appended to the current row of the table. Then the function returns the completed rows which is appended to the table body using innerHTML. The second function prompts the user to enter in a range of numbers to be multiplied in the table. The function uses loop iteration to generate the multiplication table, starting with the row and column headers. The results of each row and column is then calculated and added to the corresponding cell. The completed table rows are then appended to the table body using innterHTML.


Math Functions
Initial Value Square Root Power of 2 Power of 3
Multiplication Table
Enter Number Range to Generate a Multiplication Table
Multiplication Table