Home » C Programming » Input & Output » Question
  1. Which of the following is the right declaration for fgets() inside the library?
    1. int *fgets(char *line, FILE *fp);
    2. char *fgets(char *line, FILE *fp);
    3. int *fgets(char *line, int maxline, FILE *fp);
    4. char *fgets(char *line, int maxline, FILE *fp);
    5. None of these
Correct Option: D

char *fgets(char *line, int maxline, FILE *fp);



Your comments will be displayed only after manual approval.