refactored parallel-line-length to use common code
line orientation task uses common code
replaced some tabcat.math.random* functions with _.sample() (which didn't exist when these were written)