Can any one calrify me giving answers to the questions based on the c program given below.
Expand|Select|Wrap|Line Numbers
- char * b, q, *r;
- b=getbuf();
- q = *b;
- r= anotherfunction(b);
- /* we want to use ‘q’ and ‘r’ here*/
- char * getbuf()
- {
- char buff[8];
- /* unspecified, buff defined here *./
- return (char *) buff;
- }
2. Is there an alternative, but equivalent, way to write the line char * getbuf() If so, what is it?
3. Is getbuf() a reasonable function?
4. Will getbuf() execute at all?
5. Please comment on line return (char *) buff;
6. Is getbuf() good practice, and why?
7. What line not given should be provided for compilation?
Please I need help very urgently .
Regards
Sahitya