C/C++ Programming Language - Set 7

10 Questions | Total Attempts: 401

SettingsSettingsSettings
Please wait...
C/C++ Programming Language - Set 7

Online MCQ Quiz on C/C++ Programming - Set 7 No. Of Questions:- 10 Time:- 10 Minutes Full Mark:- 100 Pass Mark:- 70 This Quiz is for those user who wants to test their knowledge/skill in C/C++ Programming Language. For more MCQ Questions and Online Quizzes please visit https://www. McqQuestions. Com


Questions and Answers
  • 1. 
    Which of the following is/are storage class
    • A. 

      Automatic

    • B. 

      Static

    • C. 

      Allocated

    • D. 

      All

  • 2. 
    What will the output of following code {      int x = 10, y = 15;      x = x++;      y = ++y;                 printf(“%d, %d \n”, x, y); }
    • A. 

      10, 15

    • B. 

      10, 16

    • C. 

      11, 16

    • D. 

      11, 15

  • 3. 
    NULL Pointer can be used as
    • A. 

      To stop indirection in a recursive data structure

    • B. 

      As an error value

    • C. 

      As a sentinel Value

    • D. 

      All

  • 4. 
    Which one of the following is not the advantages of functions?
    • A. 

      Debugging is easier

    • B. 

      Testing is easier

    • C. 

      Recursive call is possible

    • D. 

      It consumes low disk space

  • 5. 
    What is the result of the following statement?       x = y = z = 0;
    • A. 

      X = 0, y = Null, z = Null

    • B. 

      X = 0, y = 0, z = 0

    • C. 

      X = 0, y = 1, z = 2

    • D. 

      The statement is incorrect

  • 6. 
    What is the result of the following statement?     X = 10;     y = ++x;
    • A. 

      X = 10, y = 10

    • B. 

      X = 10, y = 11

    • C. 

      X = 11, y = 10

    • D. 

      X = 11, y = 11

  • 7. 
    Which of the following statement creates infinite loop?
    • A. 

      For ( ; ; )

    • B. 

      While ( ; ; )

    • C. 

      When ( ; ; )

    • D. 

      If( ; ; )

  • 8. 
    The use of “break” Statement
    • A. 

      To terminate a case in the switch statement

    • B. 

      To force immediate termination of a loop

    • C. 

      Both

  • 9. 
    To use the function tolower(), which of the following header file should include
    • A. 

      String.h

    • B. 

      Conio.h

    • C. 

      Ctype.h

    • D. 

      Don’t need any header file

  • 10. 
    What is the function overloading?
    • A. 

      Calling a function from another function

    • B. 

      Having more than one functions of same name

    • C. 

      Calling a function from itself

    • D. 

      There is no such term in C/C++

Back to Top Back to top