If the desired length of each line is n, then a line can be divided into three possible ways:
1. The line has exactly n characters, and hence doesn’t need any processing
2.. If the line has more than n characters, then we can always choose maximum number of words that can fit into a length of n characters, and send the remaing in the next line.
3.