These are sample questions that are very similar to the ones I will ask on the final.
/* return protection mode of the named file */
short int protmode(void)
{
struct stat stbuf;
char inbuf[100];
gets(&inbuf);
stat(inbuf, &stbuf);
return(stbuf.st_mode&0777);
}
You can also obtain a PDF version of this. | Version of November 28, 2016 at 12:54PM |