Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Computer Science please help me answering these questions. Thanks !! Interfaces

ID: 3749454 • Letter: C

Question

Computer Science please help me answering these questions. Thanks !!

Interfaces andInheritance 2. (8 points) Given the following Java code fragment List targetList-new ArrayListO; List other -new ArrayList (); List scores new LinkedList LinkedList namesnew LinkedList); ArrayList exile; State if each of the following lines of code compile without syntax error. Circle the appropriate answer (a) exile : scores; A. Yes B. No (b) exile List(); new A. Yes B. No (c) target1st = other; A. Yes B. No (d) targetList -scores; A. Yes B. No (e) (f) scores (g) scores new ArrayList; (h) exile = target1st; List(); other A. Yes B. No new exile; A. Yes B. No A. Yes B. No A. Yes B. No 3. (4 points) Identify any four methods every class in Java inherits from the Object super-class.

Explanation / Answer

Answer A;
Yes, it will worl
Answer B:
No, it will give error,we cant create object for List
Answer C:
No, Type missmatch error
Answer D:
Yes, it will work both same type
Answer E:
No, it will give error,we cant create object for List
Answer F:
Yes, it will work
Answer G:
Yes it will work
Answer F:
it will work, as both are same types

Answer 3:
equals()
hashCode()
toString()
wait()

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote