Question: Is anything wrong with the code below? If yes, explain how to fix it. ArrayList stringList = new ArrayList(); stringList.add(hello); String greeting = stringList.remove(0);
Is anything wrong with the code below? If yes, explain how to fix it. ArrayList stringList = new ArrayList(); stringList.add("hello"); String greeting = stringList.remove(0);
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
