Single Choice Not Set

QWhat is the output of this C code?

    #include <stdio.h>
    struct point
    {
        int x;
        int y;
    };
    struct notpoint
    {
        int x;
        int y;
    };
    void foo(struct point);
    int main()
    {
        struct notpoint p1 = {1, 2};
        foo(p1);
    }
    void foo(struct point p)
    {
        printf("%d\n", p.x);
    }

ID: #2661 Structure in C Language 1,074 views
Question Info
#2661Q ID
Not SetDifficulty
Structure in C LanguageTopic

Choose the Best Option

Click any option to instantly check if you're correct.

  • A Compile time error
  • B 1
  • D Undefined
Correct Answer

Explanation

Compile time error

Share This Question

Challenge a friend or share with your study group.