Check If It Is a Straight Line

LeetCode 1232. The input is a list of distinct points, each given as a two-element integer array [x, y]. Determine whether all points lie on the same straight line.

Examples
Input: [[0,0],[4,0],[8,0]]
Output: true
Hints

Check If It Is a Straight Line

**LeetCode 1232.** The input is a list of distinct points, each given as a two-element integer array `[x, y]`. Determine whether all points lie on the same straight line.