Java_2

Java_2

University

10 Qs

quiz-placeholder

Similar activities

Round 2 for Preplacement Bootcamp

Round 2 for Preplacement Bootcamp

University

15 Qs

Teste python- Unesp-Jaboticabal

Teste python- Unesp-Jaboticabal

University

10 Qs

07 - Map

07 - Map

University

15 Qs

Computer Network

Computer Network

University

10 Qs

Algoritmos y Estrutura de datos S2

Algoritmos y Estrutura de datos S2

University

10 Qs

AS - Quiz 3

AS - Quiz 3

University

11 Qs

Microcontroller

Microcontroller

University

15 Qs

Components of GIS & Levels/Scales

Components of GIS & Levels/Scales

University

12 Qs

Java_2

Java_2

Assessment

Quiz

Computers

University

Practice Problem

Hard

Created by

lawrance r

Used 1+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the default value of an int in Java?

0.0

null

0

Undefined

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is not a primitive data type in Java?

float

boolean

String

char

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the size of a double data type in Java?

4 bytes

8 bytes

2 bytes

16 bytes

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which keyword is used to declare a constant variable in Java?

final

constant

static

var

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the result of 5 / 2 if both operands are integers?

2.5

2

3

Error

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What happens if there is no else block after an if statement?

Compilation error

Program terminates

Only the if block executes if the condition is true

The next if block executes

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What happens if a switch statement does not contain a break?

Compilation error

Only the matching case executes

Fall-through occurs (subsequent cases execute until a break)

None of the above

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?

Discover more resources for Computers