C Multiple Choice Questions

  1. Which of the following storage classes have global visibility in C?
    1. Auto
    2. Static
    3. Extern
    4. Register
Answer :
C
Explanation:
Added By : Deepak

  1. A full binary tree with n leaves contains
    1. n nodes
    2. 2n - 1 nodes
    3. log2 n nodes
    4. 2n nodes
Answer :
B
Explanation:
Added By : Deepak


  1. The Case keyword is followed by?
    1. Float values
    2. Character values
    3. Integer values
    4. Both b&c
Answer :
D
Explanation:
Added By : Sahil Sharma

  1. Type of data and its value is described dy
    1. Constants
    2. Variables
    3. Data Type
    4. None of the above
Answer :
B
Explanation:
Added By : Jayesh

  1. myarr[5] is equivalent of?
    1. &(myarr + 5)
    2. *(myarr + 5)
    3. (*myarr + 5)
    4. None of the above
Answer :
B
Explanation:
Added By : Raju

  1. How to make an infinity loop in C?
    1. loop: ..... goto loop;
    2. for(;;) { }
    3. while(1) { }
    4. All of the above
Answer :
D
Explanation:
Added By : Raju


  1. What does the following declaration mean? int (*ptr) [10];
    1. ptr is an array of pointers of 10 integers.
    2. ptr is a pointer to an array of 10 integers.
    3. ptr is an array of 10 integers.
    4. None of the above
Answer :
B
Explanation:
Added By : Rohan

  1. The correct way to round off a floating number x to an integer value is
    1. y = int (x + 0.5)
    2. y = (int) (x + 0.5)
    3. y = (int) x + 0.5
    4. y = (int) ((int)x + 0.5)
Answer :
B
Explanation:
Added By : Mayank

Post Your Question
Social Sharing
Search