Multi-Language Programming Fundamentals Quiz

Test your knowledge of fundamental programming concepts across C#, Java, JavaScript, and C++ including value types, OOP principles, and language-specific syntax.

20 Questions Published

Questions

Question 1 True/False

Methods that work on the data are called accessor methods.

  1. True
  2. False
Question 2 True/False

Methods that work on the data are called accessor methods.

  1. True
  2. False
Question 3 True/False
  1. JavaScript can only run on Windows
  1. True
  2. False
Question 4 Multiple Choice (Single Answer)

Which of the following is NOT a value type?

  1. Struct
  2. Delegate
  3. string
  4. Enumeration
Question 5 Multiple Choice (Multiple Answers)

Which of the following are true about Constructors?

  1. Member Function
  2. Same name as Class name
  3. Default constructor initializes all non-initialized fields and variables to zero.
  4. Compiler adds an empty constructor, if we do not write our own constructor
Question 6 Multiple Choice (Single Answer)

Which is true about applet?

  1. Applet version has main method
  2. GUI components are added explicitly to the Applet
  3. Aplet class is declared private
  4. None of the above
Question 7 Multiple Choice (Single Answer)

JFC Stands for

  1. Java Foundation Course
  2. Java Fundamental Classes
  3. Java Foundation Classes
  4. None of the above
Question 8 True/False

Java APIs are libraries of compiled code?

  1. True
  2. False
Question 9 Multiple Choice (Single Answer)

Which of the following is NOT a value type?

  1. Struct
  2. Delegate
  3. string
  4. Enumeration
Question 10 Multiple Choice (Single Answer)

A boolean in C# is

  1. BOOL
  2. bool
  3. Boolean
  4. boolean
Question 11 True/False

True or False. Is Foo.Print() a valid statement? Given a class Foo and it has a function public void Print (); Foo f = new Foo (); Foo.Print ();

  1. True
  2. False
Question 12 True/False

True or False. Like in C++, using exception does carry some performance penalty

  1. True
  2. False
Question 13 Multiple Choice (Single Answer)

Which of the following is jagged array creation?

  1. string [,,] aMatrix;
  2. string [][][] aMatrix;
  3. int [][]aInt= new int[3][];
  4. None of the above.
Question 14 Multiple Choice (Single Answer)
  1. JavaScript is ...
  1. same as Java
  2. kind of like Java
  3. different than Java
  4. written part of Java
Question 15 Multiple Choice (Single Answer)
  1. JavaScript is ...
  1. subjective
  2. objective
  3. evil
  4. object based
Question 16 Multiple Choice (Single Answer)
  1. To comment out a line in JavaScript ...
  1. Precede it with two forward slashes, i.e. '//'
  2. Precede it with an asterisk and a forward slash, i.e. '*/'
  3. Precede it with an asterisk, i.e. '*'
  4. Precede it with a forward slash and an asterisk, i.e. '/*'
Question 17 True/False

Methods that work on the data are called accessor methods.

  1. True
  2. False
Question 18 True/False

Methods that work on the data are called accessor methods.

  1. True
  2. False
Question 19 True/False
  1. JavaScript can only run on Windows
  1. True
  2. False
Question 20 Multiple Choice (Single Answer)

Which of the following is NOT a value type?

  1. Struct
  2. Delegate
  3. string
  4. Enumeration