Single Choice Not Set

QCan the above code be compiled successfully?

    #include <stdio.h>
    struct p
    {
        int k;
        char c;
        float f;
    };
    int main()
    {
        struct p x = {.c = 97, .f = 3, .k = 1};
        printf("%f\n", x.f);
    }

ID: #2648 Structure in C Language 2,480 views
Question Info
#2648Q ID
Not SetDifficulty
Structure in C LanguageTopic

Choose the Best Option

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

  • A Yes
  • B No
  • C Depends on the standard
  • D Depends on the platform
Correct Answer

Explanation

Depends on the standard

Share This Question

Challenge a friend or share with your study group.