I am having a problem with the following lines where car is a String array which has not been initialized/has no elements.
car
String
String c
I think you are looking for this
String[] car = new String[10]; int size = car.length;