Home / C Programming / Typedef :: General Questions

C Programming :: Typedef

  1. In the following code, the P2 is Integer Pointer or Integer?

     typedef int *ptr;
     ptr p1, p2; 
    

     

  2. A.

    Integer

    B.

    Integer pointer

    C.

    Error in declaration

    D.

    None of above

    View Answer

    Workspace

    Discuss Discuss in Forum


  3. In the following code what is 'P'?

      typedef char *charp;
      const charp P; 

     

  4. A.

    P is a constant

    B.

    P is a character constant

    C.

    P is character type

    D.

    None of above

    View Answer

    Workspace

    Discuss Discuss in Forum


  5. What is x in the following program?

     #include
      int main()
      {    
        typedef char (*(*arrfptr[3])())[10];    
        arrfptr x;     
        return 0; 
     }
    

  6. A.

    x is a pointer

    B.

    x is an array of three pointer

    C.

    x is an array of three function pointers

    D.

    Error in x declaration

    View Answer

    Workspace

    Discuss Discuss in Forum