Question: USING JAVASCRIPT AND BUTTON ONCLICK IN THE BODY - A magic square is a two - dimensional array of positive integers in which the fol
USING JAVASCRIPT AND BUTTON ONCLICK IN THE BODY A magic square is a twodimensional array of positive integers in which the fol
lowing is true:
The number of rows equals the number of columns.
Every row, column, and the two diagonals add up to the same number.
Create a web page with a table that has four rows and four columns. Allow the
user to enter values for each cell. Store these values in a twodimensional array
named magic and determine if it is a magic square.
Note: if we call the array magic then the sums of the two diagonals are as follows:
diagonalmagicmagicmagicmagic;
Save the page with the filename magic. htm and submit your work as
instructed by your teacher.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
