Add items to the arraylist, one at a time, based on user


Following code creates a simple ArrayList:
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;
public class Ex01 {
public static void main(String[] args) throws IOException {
BufferedReader userInput = new BufferedReader
(new InputStreamReader(System.in));
ArrayList myArr = new ArrayList();
myArr.add("Zero");
myArr.add("One");
myArr.add("Two");
myArr.add("Three");
}
}
Starting with this provided code, add the following functionality:
1) Add items to the ArrayList, one at a time, based on user typed input. The user will be prompted for the String to be stored in the
ArrayList and then hit enter. The user will be able to continue to add items to the ArrayList until they just hit enter without typing
anything. 

Request for Solution File

Ask an Expert for Answer!!
Programming Languages: Add items to the arraylist, one at a time, based on user
Reference No:- TGS089359

Expected delivery within 24 Hours