title: c programming check if key pressed without stopping program
body: <p>as you know, when using getch() in windows, the applications waits for you until you press a key, </p>
  
  <p>how can i read a key without freezing the program , example : </p>
  
  <pre><code>void main(){
    char   c;
    while(1){
    printf("hello\n");
    if (c=getch()) {
    .
    .
    .
    }  
  }
  </code></pre>
  
  <p>thank you.</p>