Longest Lines solutio