MCQ of C/C++ Programming Language – Set 6

This is the another set of Multiple Choice Questions of C/C++ Programming Language. Here in this set you will get 10 MCQ questions related to C or C++ programming language and four options to each questions, only one options is correct answer. First select your answer and tally with the correct answer which is given at the bottom of this question set.

MCQ of Microsoft Excel

Multiple Choice Questions of C, C++ Programming Language

6.1  What is the correct value to return to the operating system upon the successful completion of a program?
A.  0
B.  1
C.  –1
D.  Programs do not return a value.

6.2  What is the only function all C++ programs must contain?
A.  start()
B.  program()       
C.  system()
D.  main()

6.3  What punctuation is used to the beginning and end of code blocks?
A.  BEGIN and END
B.  ( and )
C.  { and }
D.  -> and <-

6.4  What punctuation must be used to end lines of C++ code?
A.  . (dot)
B.  ‘ (single quote)
C.  ; (semi-colon)
D.  : (colon)

6.5  Which of the following is a correct comment?
A.  */ Comments */
B.  /* Comment */
C.  ** Comment **
D.  { Comment }

6.6  Which of the following is not a correct variable type?
A.  double
B.  float
C.  int
D.  real

6.7  Which of the following is the correct operator to compare two variables?
A.  =
B.  ==
C.  :=
D.  equal

6.8  Which of the following is the Boolean operator for logical and?
A.  &
B.  &&
C.  |&
D.  ||

6.9  The directives for the preprocessors begin with
A.  Ampersand symbol (&)
B.  Less than symbol (<)
C.  Two Slashes (//)
D.  Number Sign (#)

6.10  The file “iostream

7 Responses to “MCQ of C/C++ Programming Language – Set 6”

  1. sud 29 June 2012 at 1:04 PM

    Dont know why alll the pages have issue in designing!

    your Advertisement placement is so wrong thaat it covers the answers portion please mend it..please..8-10 time I have to laod the page and and stop it quickly before Ad comes to see the answer.

    So much of help though, nice spot for MCQs for quick revison.

    • Ganesh Maharjan 22 July 2012 at 6:03 PM

      Dear Sud,
      Sorry for the problem you comment, actually that’s not the problem with designing of site and advertisement placement, you can get answer of MCQ Questions just by clicking on the word “Answer”. Just click on the “Answer” word.
      Hope you don’t have to reload the page 8-10 times.
      Thanks for your comment.

      • pooja 4 June 2015 at 1:36 AM

        still not getting answers on a click..:)

  2. Sayani Dutta 28 November 2017 at 2:53 AM

    It is the same set given before as set-4.

  3. obaid 27 August 2020 at 7:04 PM

    answer section is disappear.

  4. obaid 27 August 2020 at 7:06 PM

    many sets have problems, some are loading partial, some do not have answer section.please fix it

  5. W. Aziz 13 December 2020 at 11:53 AM

    Your add covers the answer list
    How we can see answer list…..
    It’s too difficult for us


Leave a Reply

error: Content is protected !!