Code works fine if the name of the string is given as parameter in function but on giving the string itself as parameter it generates error
Why do I get a segmentation fault when writing to a "char *s" initialized with a string literal, but not "char s[]"?