Question: Q 2 . Create a class Arrclass and define ArrayList to add 5 color names ( String ) , e . g . : blue,
Q Create a class Arrclass and define ArrayList to add color names String eg: blue, black, green, red, yellow.
Print the ArrayList using foreach
Delete the last item
Print the second item
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
