max points on a line.
minor refactor.