A string consists of N lines seperated by end-of-line characters code example Example: split by new line java String lines[] = string.split("\\r?\\n");