Question 19 a Consider the following statement, which is intended to create an ArrayList named years that can be used to store elements both of type Integer and of type String. /* missing code */ =...


Question 19 a<br>Consider the following statement, which is intended to create an ArrayList named years that can be used to store elements both of type Integer and of type String.<br>/* missing code */ = new ArrayList();<br>Which of the following can be used to replace /* missing code */ so that the statement compiles without error?<br>ArrayList years<br>B<br>ArrayList years()<br>ArrayList years[]<br>D<br>ArrayList<Integer> years<br>E<br>ArrayList<String> years<br>

Extracted text: Question 19 a Consider the following statement, which is intended to create an ArrayList named years that can be used to store elements both of type Integer and of type String. /* missing code */ = new ArrayList(); Which of the following can be used to replace /* missing code */ so that the statement compiles without error? ArrayList years B ArrayList years() ArrayList years[] D ArrayList years E ArrayList years

Jun 09, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here