Greetings ,
I wrote a function that will be removing non alpha characters and copy name or word for name .My problem is I am confused how to pass the argument or string to my function so that anywhere I call the function ,the function will know which of the string or argument to read .I need help on how to do this .This is my function.
Code:
int get_Name( char *name ) {
int c;
while( c = getchar()!=EOF && !isalpha(c) ) {
;
}
if( c == EOF ) {
;
}
*name = c;
name = name + 1;
while( c = getchar()!=EOF && isalpha(c)) {
*name = c;
name = name + 1;
}
*name = '\0';
return 0;
}