Search Header Logo

MCQ-4 CSE Q

Authored by Amit Mandal

Computers

University

Used 1+ times

MCQ-4 CSE Q
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

17 questions

Show all answers

1.

OPEN ENDED QUESTION

30 sec • Ungraded

Name

Evaluate responses using AI:

OFF

2.

OPEN ENDED QUESTION

30 sec • Ungraded

Roll No

Evaluate responses using AI:

OFF

3.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

Media Image

Choose the correct option based on this program:

It prints the following: The list is: [10, 20]
It prints the following: The list is: [20, 10]
It results in a compiler error
It results in a runtime exception

4.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

Media Image

What is the output of the following program?

It prints the following: First type: class java.util.LinkedList Second type:class java.util.LinkedList
It prints the following: First type: class java.util.LinkedList
It results in a compiler error
It results in a runtime exception

5.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

Media Image

What is the output of the following program?

[1, 2, 3]
[1, 2]
[2, 1]
An exception occurs at runtime

6.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Which of the following options can throw a NullPointerException?

TreeSet s = new TreeSet<>(); s.add(null);
HashMap m = new HashMap<>(); m.put(null, null);
ArrayList arr = new ArrayList<>(); arr.add(null);
HashSet s = new HashSet(); s.add(null);

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

HashSet internally uses?

Set
HashMap
List
Collection

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?