Java MCQ-1

Java MCQ-1

University

29 Qs

quiz-placeholder

Similar activities

C Quiz 1

C Quiz 1

University

25 Qs

java collections

java collections

University

31 Qs

Java Programming Quiz

Java Programming Quiz

University

26 Qs

Java Quiz

Java Quiz

University

25 Qs

PRA PSPM SC025 ( F01 KML )

PRA PSPM SC025 ( F01 KML )

University

24 Qs

JAVA - EXCEPTION & MULTITHREADING

JAVA - EXCEPTION & MULTITHREADING

University

25 Qs

TechZoom24-BugBash_Prelims

TechZoom24-BugBash_Prelims

University

25 Qs

 Milking Minds 17-01-24

Milking Minds 17-01-24

University

25 Qs

Java MCQ-1

Java MCQ-1

Assessment

Quiz

Computers

University

Hard

Created by

Amit Mandal

Used 2+ times

FREE Resource

29 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is not the use of “this” keyword in Java?

Referring to the instance variable when a local variable has the same name

Passing itself to the method of the same class

Passing itself to another method

Calling another constructor in constructor chaining

2.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

Media Image

What will be the output of the following Java program?

Compilation error

Runtime error

5 6 5 6

5 6 5

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will be the error in the following Java code?

b cannot contain value 50

b cannot contain value 100, limited by its range

No error in this code

* operator has converted b 50 into int, which can not be converted to byte without casting

4.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

Media Image

What will be the output of the following Java program?

1

2

6

7

5.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

Media Image

What will be the output of the following Java program?

5

6

14

compilation error

6.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

Media Image

What will be the output of the following Java program?

1

2

Runtime Error

Compilation Error

7.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

Media Image

What will be the output of the following Java code?

int float method

float int method

compile time error

run time error

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?