A
A
aeaeae12021-07-06 22:15:05
Java
aeaeae1, 2021-07-06 22:15:05

How to break a string every two spaces in java?

Good day! I have a code that wraps a string through every space How to make it wrap every two or 3 spaces. In general, I need to have two or three words on each line. Or can you tell me some other method better than through split? in textview.

String[] arrayString = string.split(" ");

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Sergey Gornostaev, 2021-07-06
@aeaeae1

Everything has been thought of before us. One and two .

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question