c gets syntax code example
Example: gets syntax
#include
#define MAX 15
int main()
{
char buf[MAX];
printf("Enter a string: ");
gets(buf);
printf("string is: %s\n", buf);
return 0;
}
#include
#define MAX 15
int main()
{
char buf[MAX];
printf("Enter a string: ");
gets(buf);
printf("string is: %s\n", buf);
return 0;
}