Type Here to Get Search Results !

C Programming MCQ with Answers [ SET - 3 ] | C Programming Quiz Questions and Answers


C Programming Quiz Questions and Answers

1. What is the value of a?:

 #define SQR(x) x*x

a = SQR(2+3);

ANSWER= (b) (SQR(2+3) is equivalent to 2+3*2+3 = 11)


2. What will be output if you will compile and execute the following c code?

void main(){

int huge*p=(int huge*)0XC0563331;

int huge*q=(int huge*)0xC2551341;




    Garbage value

ANSWER= (A) 200


3. Which of the following language is the predecessor to C Programming Language?




4. C programming language was developed by

    Dennis Ritchie
    Ken Thompson
    Bill Gates
ANSWER= (A) Dennis Ritchie


5. What is the output? int c, d = 90;

c = d--; 

printf("%d %d", c, d);

     89 90,
    90 89,
     89 89,
ANSWER= (B) 90 89,


6. The _______ is used to break out of the case statements.

ANSWER= (B) break


7. Who is father of C Language?

    Bjarne Stroustrup
    Dennis Ritchie
    James A. Gosling
ANSWER= (B) Dennis Ritchie


8. Pick the correct output: 

int p = 500, g = 5;

printf("%d", p ==q);



9. C supports the ______ statement to branch unconditionally from one point to another in the program.

ANSWER= (B) goto


10. C Language developed at _____?

    AT & T’s Bell Laboratories of USA in 1972
    AT & T’s Bell Laboratories of USA in 1970
    Sun Microsystems in 1973
ANSWER= (A) AT & T’s Bell Laboratories of USA in 1972


11. What is the result of 16>>2?



12. Which is the correct syntax to declare constant pointer?

    int *const constPtr;
    *int constant constPtr;
    const int *constPtr;

ANSWER= (D) A and C both


13. C Language is a successor to which language.?

    D Language
ANSWER= (A)  B Language


14. int p = 35; q = 145; p = p^q; q = p^q; p= p ^q; printf("%d %d", p, q); then output will be -

    35 145,
    0  5,
    145 35.
ANSWER= (C) 145 35.


15. In which linked list last node address is null?

    Doubly linked list
    Circular list
    Singly linked list
ANSWER= (C) Singly linked list


16. Low level language is .?

    Human readable like language.
    language with big program size.
    language with small program size.
ANSWER= (D) Difficult to understand and readability is questionable.


17. Consider the variable char c = 'p'; int i = 6, f = 2; the result of the expression c< (i+ f) is -



18.  x – =  y + 1 ; does the same as

    x = x – y + 1
    x = x – y – 1
     x  = – x + y + 1
ANSWER= (D) x  = x – y – 1


19. The default parameter passing mechanism is

     call by value
    call by reference
    call by value result
ANSWER= (A) call by value


20. The expression 4 + 6 / 3* 2 -2 + 7 % 3 evaluates to



21. Let  x be an array. Which of the following operation are illegal?

     ++ x
    x + 1
ANSWER= a,b,c


22. (a) If a = 11 and b = 3 what is the value of a % b? -




23. A set names can be represented as a

    two-dimensional array of characters
    one- dimensional array of strings
    one- dimensional array of pointers to character
ANSWER= a,b, c


24. If x = y = z = -1 then what is the output of the following ++x || ++y && + printf ("z=%d", z):

ANSWER= (B) -1


25. Operand of indirection operator is

    ordinary variable
     integer constant
    pointer variable
ANSWER= (C) pointer variable


26. Which of the following statement about functions of false?

    A function can call itself.
    A function can call another function.
    Constants can appear in the formal argument list.
ANSWER= (C) Constants can appear in the formal argument list.


27. "int a = -2";then memory location of a contains - 

ANSWER= (D) none of these.


28. For 16-bit compiler allowable range for integer constants is ______ ?

    -3.4e38 to 3.4e38
     -32767 to 32768
    -32768 to 32767
ANSWER= (C) -32768 to 32767


29. Write the output of the following program 

fragment main ())


main ()

printf ("Hello world"); }

    Compilation error, 
    stack overflow error, 
    infinite loop,
ANSWER= (B) stack overflow error, 


30. C is ______ Language?

    low level
     high level
    assembly level
ANSWER= (A) low level


Related Quaries:

c programming mcq with answers pdf
c programming mcq pdf
100 multiple choice questions in c programming
c programming quiz questions and answers
c programming test questions and answers
c programming quiz
c programming quiz pdf

  Friends if you like this post,kindly comment bellow and do share your responce.Thank You for Visiting.

Post a Comment

* Please Don't Spam Here. All the Comments are Reviewed by Admin.

Top Post Ad

Below Post Ad