So in class we have been discussing matrix inverses and the quickest way that I know of is to get a matrix A, and put it side by side with the identity matrix, like $[A|I_{n}]$ and apply the Gauss-Jordan algorithm until it is of the form $[I_{n}|A^{-1}$], where $A^{-1}$ will show up assuming A is invertible.
We also discussed using the formula $A^{-1}=\frac{\operatorname{adj}(A)}{\det(A)}$, however after a few examples, it was clear that this formula would take far too long to find the inverse of A as the matrix size got bigger.
Is the first method I described the quickest way to find a inverse of a matrix or is there a more efficient way?