Category: Programming

  • Python Questions and Answers – Lists – 4

    Python Questions and Answers – Lists – 4

    Python Programming Questions & Answers focuses on “Lists”. Q 1. What will be the output of the following Python code? def f(i, values = []): values.append(i) return values f(1)f(2)v = f(3)print(v) A. [1] [2] [3]B. [1] [1, 2] [1, 2, 3]C. [1, 2, 3]D. 1 2 3 Show Answer Answer:-C. [1, 2, 3] Explanation Execute in…

  • C++ Programming Questions and Answers – Large Objects

    C++ Programming Questions and Answers – Large Objects

    C++ Multiple Choice Questions focuses on “Large Objects”. One shall practice these questions to improve their C++ programming skills needed for various interviews (campus interviews, walk-in interviews, company interviews) entrance exams and other competitive exams. These questions can be attempted by anyone focusing on learning C++ programming language. They can be a beginner, fresher, engineering…

  • C++ Programming Questions and Answers – Subscripting

    C++ Programming Questions and Answers – Subscripting

    C++ interview questions and answers focuses on “Subscripting”. One shall practice these interview questions to improve their C++ programming skills needed for various interviews (campus interviews, walk in interviews, company interviews)entrance exams and other competitive exams. These questions can be attempted by anyone focusing on learning C++ programming language. They can be a beginner, fresher,…

  • Python Questions and Answers – Lists – 3

    Python Questions and Answers – Lists – 3

    Python Programming Questions & Answers focuses on “Lists”. Q 1. Suppose list1 is [3, 4, 5, 20, 5, 25, 1, 3], what is list1 after list1.reverse()?A. [3, 4, 5, 20, 5, 25, 1, 3]B. [1, 3, 3, 4, 5, 5, 20, 25]C. [25, 20, 5, 5, 4, 3, 3, 1]D. [3, 1, 25, 5, 20,…

  • Operators and expressions of JavaScript

    Operators and expressions of JavaScript

    Q 1. See the given code of JavaScript and choose the correct output from the following: var string1 = “40”;   varvalueinit=50;   alert( string1 +intvalue);   A. 90 B. 4050 C. 4090 D. Exception Show Answer Answer:-B. 4050 Explanation In JavaScript, the alert method does the typecasting and converts the value of the variable “valueinit” to a string after that it concatenates…

  • Variables in JavaScript ll

    Variables in JavaScript ll

    Q 1. Which of the following variables takes precedence over the others if the names are the same? A. Global variable B. The two of the above C. The local element D. None of the above Show Answer Answer:-C. The local element Explanation In JavaScript, the local variable takes precedence over the global variable if…

  • JavaScript MCQ

    JavaScript MCQ

    Q 1. Which type of JavaScript language is ___ A. Object-Based B. Object-Oriented C. Assembly-language D. High-level Show Answer Answer:-A. Object-Based Explanation JavaScript is not a pure OOP’s (object oriented programming) based languages such as PHP, java or many other languages, although it is an object-based language. It is not OOP’s based language, because it…

  • C++ Programming Questions and Answers – Complex Number Type

    C++ Programming Questions and Answers – Complex Number Type

    C++ interview questions and answers focuses on “Complex Number Type”. One shall practice these interview questions to improve their C++ programming skills needed for various interviews placements, entrance exams and other competitive exams. These questions can be attempted by anyone focusing on learning C++ programming language. They can be a beginner, fresher, engineering graduate or…

  • C++ Programming Questions and Answers – Namespaces – 2

    C++ Programming Questions and Answers – Namespaces – 2

    C++ Programming Multiple Choice Questions & Answers (MCQs) focuses on “Namespaces – 2”. Q 1. Pick the incorrect statement for namespaces in C++.A. Namespace declarations are always global scopeB. Keyword namespace is used at the starting of a namespace definitionC. Namespace has access specifiers like private or publicD. Namespace definitions can be nested Show Answer…

  • C++ Programming Questions and Answers – Conversion Operators

    C++ Programming Questions and Answers – Conversion Operators

    C++ Multiple Choice Questions focuses on “Conversion Operators”. One shall practice these questions to improve their C++ programming skills needed for various interviews (campus interviews, walk-in interviews, company interviews), placements, entrance exams and other competitive exams. These questions can be attempted by anyone focusing on learning C++ programming language. They can be a beginner, fresher,…