*see the title. I basically need it to create a blank array that can be any dimension like 40×60. Basically maybe something like makeArray(3, 4) makes an array like:
[][][]
[][][]
[][][]
[][][]
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Javascript arrays are dynamic in size. However, if you wish to create an array of a specific size, the
Arrayconstructor takes an optional length argument:Slightly shorter:
UPDATE