Forum Discussion
Altera_Forum
Honored Contributor
12 years agohow to flush stdin buffer between two scanf?
Hi, I think this is a beginner-level question. Much appreciate your answers in advance! The following is my simple C-code: #include <stdio.h># include <string.h>
void main(void)
{
...
Altera_Forum
Honored Contributor
12 years agoThank you for your reply,dsl!
Do you imply I should always use cin and cout instead of scanf and printf? What if I have to write some code in a pure C environment?