JavaScript Program to Find the Rank of a Matrix
Given a matrix of size M x N, your task is to find the rank of a matrix using JavaScript. Example: Input: mat[][] = [[10, 20, 10], [20, 40, 20], [30, 50, 0]]Output: Rank is 2Explanation: Ist and 2nd rows are linearly dependent. But Ist and 3rd or 2nd and 3rd are independent. Input: mat[][] = [[10, 2