C | Structure & Union | Question 1

Last Updated :
Discuss
Comments

Choose the correct output from the options given below:

C
#include‹stdio.h›
int main()
{
    struct site
    {
        char name[] = "GeeksQuiz";
        int no_of_pages = 200;
    };
    struct site *ptr;
    printf("%d ", ptr->no_of_pages);
    printf("%s", ptr->name);
    getchar();
    return 0;
}

200 GeeksQuiz

200

Runtime Error

Compiler Error

Tags:
Share your thoughts in the comments