title: How to declare initialize and use 2 dimensional arrays in Java Script Using a text from html page
body: <p>How to declare , initialize and use 2 dimensional arrays in javascript,
  If I write </p>
  
  <pre><code>var arr=new array(2,2)
  </code></pre>
  
  <p>is it correct to declare a array with 2 rows and two columns </p>
  
  <p>and is it fine if  i declare an array variable globally and allocate space in some function.
  or is the following is correct?</p>
  
  <pre><code>var arr;
  //Some operations
  function(){
  arr[0][1]=8;
  };
  </code></pre>
  
  <p>I dont know how can you mark it as duplicate please read the description of the question not the title i want to declare the array without initializing it are you getting my point if not please ........ you are pointing it to the static declaration of an array and that i know and i learnt from the basics of programming 10 years ago so if you dont know know English kindly go to some language school and come back</p>