exam questions

Exam 1z0-809 All Questions

View all questions & answers for the 1z0-809 exam

Exam 1z0-809 topic 1 question 27 discussion

Actual exam question from Oracle's 1z0-809
Question #: 31
Topic #: 2
[All 1z0-809 Questions]

Given:
public interface Moveable<Integer> {
public default void walk (Integer distance) {System.out.println("Walking");) public void run(Integer distance);
}
Which statement is true?
Moveable can be used as below:
A.
Moveable<Integer> animal = n - > System.out.println("Running" + n); animal.run(100); animal.walk(20);
Moveable can be used as below:
B.
Moveable<Integer> animal = n - > n + 10;
animal.run(100);
animal.walk(20);
Moveable can be used as below:
C.
Moveable animal = (Integer n) - > System.out.println(n);
animal.run(100);
Moveable.walk(20);
Movable cannot be used in a lambda expression.
D.

Show Suggested Answer Hide Answer
Suggested Answer: B

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
thetech
Highly Voted 4 years, 8 months ago
Answer is A. Tested.
upvoted 6 times
...
asdfjhfgjuaDCV
Most Recent 4 months, 3 weeks ago
Answer is A tested
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago