BPSC TRE – Java Programming & OOP Concepts | Test 2

Questions 6-10 of 50

0% completed (0/50 answered)
Your score 0/50 0 answered
Correct 0 Incorrect 0 Unanswered 50 Accuracy 0%

Question 6

MCQ · Single Correct 1 mark

Which Java 8 Stream API intermediate operation is used to transform each element of a stream into another object using a Function mapper?

Answers for question 6

Question 7

MCQ · Single Correct 1 mark

Which Stream API terminal operation performs a reduction on the elements of the stream using an associative accumulation function and returns an Optional?

Answers for question 7

Question 8

MCQ · Single Correct 1 mark

Introduced in Java 7, what is the primary benefit of the try-with-resources statement?

Answers for question 8

Question 9

MCQ · Single Correct 1 mark

Which exception is thrown by the Java Virtual Machine when an application attempts to access a member or method of an object reference that points to null?

Answers for question 9

Question 10

MCQ · Single Correct 1 mark

Which Java I/O class is specifically designed for efficient reading of characters, arrays, and lines by buffering character data from an underlying Reader?

Answers for question 10
Scroll to Top