title: c++ dynamic size of the array
body: <p>I have got a small problem with 1D array in c++. I have got a function line this:</p>
  
  <pre><code>void func(int (&amp;array)[???])
  {
      // some math here;
  
      "for" loop {
          array[i] = something;
      }
  }
  </code></pre>
  
  <p>I call the functions somewhere in the code, and before I made math I'm not able to know dimension of the array. The array goes to the function as a reference!, because I need it in the main() function. How I can allocate array like this?, so array with ?? dimension goes to the function as reference then I have to put the dimension and write to it some values.</p>