C question on functions
Posted
by benjamin button
on Stack Overflow
See other posts from Stack Overflow
or by benjamin button
Published on 2010-04-09T12:27:02Z
Indexed on
2010/04/09
12:33 UTC
Read the original article
Hit count: 275
some times i see that functions are defined as below:
read_dir(dir)
char *dir;
{
DIR * dirp;
struct dirent *d;
/* open directory */
dirp = opendir(dir);
......... so on
here what is the importance of the statement
char *dir;
what is the intension behind declaring the pointer soon after the function name and then starting the function body.
© Stack Overflow or respective owner