cs50/src4/get3.c

12 lines
182 B
C

// Dangerously gets a string from user using scanf with array
#include <stdio.h>
int main(void)
{
char s[4];
printf("s: ");
scanf("%s", s);
printf("s: %s\n", s);
}