Hi how do I remove [] in my arraylist my sample output is [[3,  6,  5,  1,  2,  8,  50,  6,  1,  3,  1,  54,  1,  3,  1]]

I just want 3,  6,  5,  1,  2,  8,  50,  6,  1,  3,  1,  54,  1,  3,  1

Recommended Answers

All 3 Replies

Member Avatar for Search_not

Could you maybe post an example of the code that prints out the array?

probably by printing in the correct way.

Look at ArrayList's stream() method and Collectors.joining

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.