New Year Sale Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: simple70

Oracle Java SE 11 Developer 1z0-819 Question # 58 Topic 6 Discussion

Oracle Java SE 11 Developer 1z0-819 Question # 58 Topic 6 Discussion

1z0-819 Exam Topic 6 Question 58 Discussion:
Question #: 58
Topic #: 6

Assuming the Widget class has a getPrice method, this code does not compile:

1z0-819 Question 58

Which two statements, independently, would allow this code to compile? (Choose two.)


A.

Replace line 5 with widgetStream.filter(a −> ((Widget)a).getPrice() > 20.00).


B.

Replace line 1 with List widgetStream = widgets.stream();.


C.

Replace line 5 with widgetStream.filter((Widget a) −> a.getPrice() > 20.00).


D.

Replace line 4 with Stream widgetStream = widgets.stream();.


Get Premium 1z0-819 Questions

Contribute your Thoughts:


Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.