Max Points on a Line

You are given an array of points where points[i] = [xi, yi] represents a point on the X-Y plane. Return the maximum number of points that lie on the same straight line.

A line is determined by any two distinct points. Points that share the same coordinates are duplicates and always lie on the same line as each other. When the input has fewer than two points, the answer is the number of points present.

Examples
Input: [[1,1],[2,2],[3,3]]
Output: 3
Hints

Max Points on a Line

You are given an array of points where `points[i] = [xi, yi]` represents a point on the X-Y plane. Return the maximum number of points that lie on the same straight line.