John wrote some text in his text editor. The text contained exactly n lines, each of which was exactly k
characters long. His younger brother came along later and might have added some line breaks in random places and removed
some of the original line breaks. Fortunately, he did not delete any of the original characters. John wants to restore
his original text and he needs your help.
You will be given a String[] lines containing the state of the text editor after the brother's edits.
Return a String[] containing exactly n elements of length k representing the original text.
|