On executing this snippet whatever input I give,the console doesn't stop getting an input,is there any possible way to terminate this snippet with an input to stdin.
#include<stdio.h>
void main()
{
char s1[100];
scanf("%[^EOF]s",s1);
or
scanf("[^\0]s",s1);
printf("%s",s1);
}