title: How to use getch() without waiting for input?
body: <pre><code> for (;;)
  {
      cout &lt;&lt; "You are playing for:" &lt;&lt; playtime &lt;&lt; "seconds." &lt;&lt; endl;
      cout &lt;&lt; "You have " &lt;&lt; bytes &lt;&lt; " bytes." &lt;&lt; endl;
      cout &lt;&lt; "You are compiling " &lt;&lt; bps &lt;&lt; " bytes per second." &lt;&lt; endl;
      cout &lt;&lt; "Press a to buy assembler monkey (produces 1 byte per second)/(cost 10 bytes)" &lt;&lt; endl;
      switch(getch())
      {
          case 'a': bytes = bytes - 10; bps++; break;
      }
      bytes = bytes + bps;
  playtime++;
  Sleep(1000);
  system("cls");
  }
  </code></pre>
  
  <p>Let's say that's my incremental game. I want refresh my game after 1 second. How can I make getch() to wait for input without stopping all other stuff?</p>