Ordering of lines