How to find the determinant of order n whose main diagonal is all 2 and other determinants are all 1

How to find the determinant of order n whose main diagonal is all 2 and other determinants are all 1


Add the number of each column to the first column, and then the first column will become the same number. Then put forward the number, and the first column will become 1. Then subtract the first row from each row below to form a diagonal matrix, except for the number in the first row, and then multiply it
The final result should be 1