Home / C Programming / Structures, Unions, Enums :: Discussion

Discussion :: Structures, Unions, Enums

  1. Point out the error in the program?

    #include 
     int main()
     {
         struct emp   
         {      
            char n[20];    
            int age;   
       };    
       struct emp e1 = {"Dravid", 23};          
       struct emp e2 = e1; 
       if(e1 == e2)   
           printf("The structure are equal");   
       return 0;
     } 
    

  2. A.

    Prints: The structure are equal

    B.

    Error: Structure cannot be compared using '=='

    C.

    No output

    D.

    None of above

    View Answer

    Workspace

    Answer : Option B

    Explanation :

    No answer description available for this question.


Be The First To Comment