Java Flashcards

Java Flashcards

University

16 Qs

quiz-placeholder

Similar activities

Java, part I

Java, part I

11th Grade - University

20 Qs

Lets explore Java

Lets explore Java

University

14 Qs

javaquizvivek

javaquizvivek

University

12 Qs

BUG BLUSTERS

BUG BLUSTERS

University

15 Qs

COSC_1436_ MOD-01 & MOD-02 Quiz

COSC_1436_ MOD-01 & MOD-02 Quiz

University

16 Qs

Java Quiz - 1

Java Quiz - 1

University

15 Qs

OOP - Java Classes

OOP - Java Classes

12th Grade - University

15 Qs

Java Flashcards

Java Flashcards

Assessment

Quiz

Computers

University

Hard

Created by

Gaurav Singh

FREE Resource

16 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is NOT a Java access modifier?

public

private

internal

protected

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the default value of a boolean variable in Java if it’s an instance variable?

true

false

null

0

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which keyword is used to prevent a class from being inherited?

static

final

abstract

private

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the size of a Java char?

1 byte

2 bytes

4 bytes

Depends on OS

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of these exceptions is unchecked in Java?

IOException

SQLException

NullPointerException

FileNotFoundException

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which collection class maintains insertion order in Java?

HashMap

HashSet

LinkedHashMap

TreeMap

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will happen if you try to inherit from a final class?

Compile-time error

Runtime error

The subclass will override it

It will work normally

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?