It doesn't know how to output the value, because there is no single value. That output indicates that the value is actually a
String array. So cast it to a
String[] and then output it however you want it outputting.
Incidentally, there is a slightly easier way of writing that loop: