About Question enthuware.ocpjp.ii.v11.2.1101 :

Help and support on OCA OCP Java Programmer Certification Questions
1Z0-808, 1Z0-809, 1Z0-815, 1Z0-816, 1Z0-817

Moderator: admin

Post Reply
liugengyu
Posts: 8
Joined: Thu Jul 09, 2020 4:09 pm
Contact:

About Question enthuware.ocpjp.ii.v11.2.1101 :

Post by liugengyu »

Option B: remove(Object key) returns V, not boolean

admin
Site Admin
Posts: 10071
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: About Question enthuware.ocpjp.ii.v11.2.1101 :

Post by admin »

Right. That is why it is not the correct option.
If you like our products and services, please help us by posting your review here.

noeloo
Posts: 61
Joined: Sat Feb 15, 2020 8:56 am
Contact:

Re: About Question enthuware.ocpjp.ii.v11.2.1101 :

Post by noeloo »

The explanation is clear, but only from options description one gets the impression that the methods are atomic in the Map interface.

pavvel
Posts: 10
Joined: Fri Dec 15, 2023 4:00 pm
Contact:

Re: About Question enthuware.ocpjp.ii.v11.2.1101 :

Post by pavvel »

I see boolean remove(Object key, Object value) int specification here:
https://docs.oracle.com/en/java/javase/ ... ntMap.html

But in the answers, it is marked as an incorrect option.
Some kind of confusion.

admin
Site Admin
Posts: 10071
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: About Question enthuware.ocpjp.ii.v11.2.1101 :

Post by admin »

Yes, but the question asks for methods that are there in ConcurrentMap in addition to Map. The method you have mentioned exists in Map that is why it is not a correct option.
If you like our products and services, please help us by posting your review here.

Post Reply

Who is online

Users browsing this forum: No registered users and 136 guests