Get string and assign its value to a char pointer
int main(void) { char *p; printf("Enter a string: "); gets(p); return 0; }