C/C++ Programming Language - Set 1

Approved & Edited by ProProfs Editorial Team
The editorial team at ProProfs Quizzes consists of a select group of subject experts, trivia writers, and quiz masters who have authored over 10,000 quizzes taken by more than 100 million users. This team includes our in-house seasoned quiz moderators and subject matter experts. Our editorial experts, spread across the world, are rigorously trained using our comprehensive guidelines to ensure that you receive the highest quality quizzes.
Learn about Our Editorial Process
| By Mcqquestions
M
Mcqquestions
Community Contributor
Quizzes Created: 23 | Total Attempts: 616,153
Questions: 10 | Attempts: 15,508

SettingsSettingsSettings
C/C++ Programming Language - Set 1 - Quiz

Online MCQ Quiz on C/C++ Programming - Set 1 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://mcqQuestions. Com


Questions and Answers
  • 1. 

    C++ was originally developed by

    • A.

      Nicolas Wirth

    • B.

      Donald Knuth

    • C.

      Bjarne Stroustrup

    • D.

      Ken Thompson

    Correct Answer
    C. Bjarne Stroustrup
    Explanation
    Bjarne Stroustrup is the correct answer because he is the creator of C++. He developed the programming language in the early 1980s as an extension of the C programming language. Stroustrup's goal was to add object-oriented programming capabilities to C, resulting in the creation of C++. His work on C++ has had a significant impact on the field of computer programming and has made C++ one of the most widely used programming languages in the world.

    Rate this question:

  • 2. 

    The standard C++ comment

    • A.

      /

    • B.

      //

    • C.

      /* and */

    • D.

      None of these

    Correct Answer
    B. //
    Explanation
    The correct answer is "//". In C++, "//" is used to indicate a single-line comment. Anything written after "//" on the same line is considered a comment and is ignored by the compiler. This allows programmers to add notes or explanations within the code without affecting its functionality.

    Rate this question:

  • 3. 

    The preprocessor directive #include is required if

    • A.

      Console output is used

    • B.

      Console input is used

    • C.

      Both console input and output is used

    • D.

      None of these

    Correct Answer
    C. Both console input and output is used
    Explanation
    The preprocessor directive #include is required if both console input and output is used. This directive allows the program to include the necessary header files that contain the declarations and definitions needed for console input and output operations. Without including the necessary header files, the program would not be able to recognize and use the functions and objects related to console input and output.

    Rate this question:

  • 4. 

    The operator << is called

    • A.

      An insertion operator

    • B.

      Put to operator

    • C.

      Either a or b

    • D.

      None of these

    Correct Answer
    C. Either a or b
    Explanation
    The operator "

    Rate this question:

  • 5. 

    The operator >> is called

    • A.

      An extraction operator

    • B.

      A get from operator

    • C.

      Either a or b

    • D.

      Get to operator

    Correct Answer
    C. Either a or b
    Explanation
    The operator ">>" is commonly used in programming languages like C++ and is known as the extraction operator. It is used to extract data from an input stream, such as reading values from the standard input or a file. Therefore, the correct answer is either "an extraction operator" or "a get from operator."

    Rate this question:

  • 6. 

    The C++ symbol <<

    • A.

      Perform the action of sending the value of expression listed as its right to the outputs strewn as the left.

    • B.

      Is used to indicate the action from right to left

    • C.

      Is adopted to resemble an arrow

    • D.

      All of above

    Correct Answer
    D. All of above
    Explanation
    The correct answer is "All of the above". The C++ symbol "

    Rate this question:

  • 7. 

    When a language has the capability to produce new data type, it is called

    • A.

      Extensible

    • B.

      Overloaded

    • C.

      Encapsulated

    • D.

      Reprehensible

    Correct Answer
    A. Extensible
    Explanation
    When a language has the capability to produce new data types, it is referred to as "extensible." This means that the language allows for the creation and implementation of new data types, providing flexibility and adaptability to the programmers. This feature enables the language to evolve and meet the changing needs of the users by introducing new data structures and functionalities. It promotes code reusability and modularity, allowing developers to extend the language's capabilities beyond its predefined types.

    Rate this question:

  • 8. 

    C++ name was suggested by

    • A.

      Rrick Mascitti

    • B.

      Bjarne Stroustrup

    • C.

      Donald Knuth

    • D.

      Ken Thompson

    Correct Answer
    A. Rrick Mascitti
  • 9. 

    What is a reference?

    • A.

      An operator

    • B.

      A reference is an alias for an object

    • C.

      Used to rename an object

    • D.

      None of these

    Correct Answer
    B. A reference is an alias for an object
    Explanation
    A reference is an alias for an object, meaning that it is another name or identifier that can be used to access and manipulate the object. This allows for multiple names to refer to the same object in memory, providing flexibility and convenience in programming.

    Rate this question:

  • 10. 

    State the object oriented languages

    • A.

      C++

    • B.

      Java

    • C.

      Eiffel

    • D.

      All of the above

    Correct Answer
    D. All of the above
    Explanation
    The correct answer is "All of the above" because C++, Java, and Eiffel are all examples of object-oriented programming languages. Object-oriented programming is a programming paradigm that organizes data and behavior into reusable structures called objects, and these languages support this paradigm by providing features such as classes, objects, inheritance, and polymorphism. Therefore, all three options listed are valid examples of object-oriented languages.

    Rate this question:

Quiz Review Timeline +

Our quizzes are rigorously reviewed, monitored and continuously updated by our expert board to maintain accuracy, relevance, and timeliness.

  • Current Version
  • Feb 17, 2023
    Quiz Edited by
    ProProfs Editorial Team
  • Jul 12, 2012
    Quiz Created by
    Mcqquestions
Back to Top Back to top
Advertisement
×

Wait!
Here's an interesting quiz for you.

We have other quizzes matching your interest.