0
What will be the output of the following C program code if the file "test.txt" is empty, readable, and exists in the appropriate directory?
#include <stdio.h>
int main() {
FILE *fp = fopen("test.txt", "r");
if (fp == NULL) {
printf("Error\n");
} else {
printf("Success\n");
fclose(fp);
}
return 0;
}- ASuccess
- BNULL
- CGarbage value
- DError
Correct answer: A