Keyboard input/Flush the keyboard buffer: Difference between revisions

m
Line 810:
<lang c>#include <stdio.h>
#include <stdlib.h>
 
 
int main(int argc, char* argv[])
Line 818 ⟶ 817:
char text[256];
getchar();
 
 
// This DOES NOT WORK properly on all modern systems including Linux & W10.
// Obsolete, don't use this. BTW, there is no fpurge in MSVC libs in 2020.
//
// fflush(stdin);
 
// Always works. The only difference is (?) that readed characters may
Line 834 ⟶ 832:
// no trace of buffered characters remain in RAM. Use with care.
//
// setvbuf(stdin, NULL, _IONBF, 0);