Get the answers you need at Westonci.ca, where our expert community is dedicated to providing you with accurate information. Get expert answers to your questions quickly and accurately from our dedicated community of professionals. Get precise and detailed answers to your questions from a knowledgeable community of experts on our Q&A platform.

Declare an ArrayList of Strings. Add eight names to the collection. Output the Strings onto the console using the enhanced for loop. Sort the ArrayList using the method Collections.sort. Output the sorted List. Shuffle the list, and output the shuffled list. Note that Collections (with an s) is a class, while Collection is an interface. The Collections class has many useful static methods for processing interfaces, including the sort method. Search for a name in the list that exists; output the location where it was found. Search for a name that is not in the list. What location is reported? Convert the list to an array using toArray. Output the elements of the array. Convert the array back into a list using asList. Output the elements of the list.

Sagot :

Answer:

---------------------------

Explanation: