title: ncurses LINES and COLS are 0?
body: <p>I am trying to learn ncurses but have hit an odd error. LINES and COLS appear to be set to 0, or else to something that is not an <code>int</code>:</p>
  
  <p>relevant parts of my code:</p>
  
  <pre><code>#include &lt;stdio.h&gt;
  #include &lt;ncurses.h&gt;
  </code></pre>
  
  <p>[...]</p>
  
  <pre><code>printf("%d\n%d\n%d\n",rand(),LINES,COLS);
  blk[i].pos[0] = (int)(rand()/LINES);
  blk[i].pos[1] = (int)(rand()/COLS);
  </code></pre>
  
  <p>This outputs:</p>
  
  <pre><code>1556162876
  0
  0
  Floating point exception
  </code></pre>
  
  <p>What am I doing wrong?</p>