nerdexam
Oracle

1Z0-815 · Question #1

Given: Which two statements can be added at line 1 in Bar to successfully compile it? (Choose two.)

The correct answer is E. public List<Object> foo(Set<CharSequence> m) { ... } F. public ArrayList<Integer> foo(Set<String> m) { ... }. See the full explanation below for the reasoning.

Question

Given:

Which two statements can be added at line 1 in Bar to successfully compile it? (Choose two.)

Exhibit

1Z0-815 question #1 exhibit

Options

  • Apublic List<Integer> foo(Set<CharSequence> m) { ... }
  • Bpublic ArrayList<Number> foo(Set<CharSequence> m) { ... }
  • Cpublic List<Integer> foo(TreeSet<String> m) { ... }
  • Dpublic List<Integer> foo(Set<String> m) { ... }
  • Epublic List<Object> foo(Set<CharSequence> m) { ... }
  • Fpublic ArrayList<Integer> foo(Set<String> m) { ... }

How the community answered

(37 responses)
  • A
    11% (4)
  • C
    3% (1)
  • D
    5% (2)
  • E
    81% (30)

Community Discussion

No community discussion yet for this question.

Full 1Z0-815 Practice