In this paper, a matrix method is employed to study the scalar quasinormal modes of Kerr as well as Kerr–Sen black holes. Discretization is applied to transfer the scalar perturbation equation into a matrix form eigenvalue problem, where the resulting radial and angular equations are derived by the method of separation of variables. The eigenvalues, quasinormal frequencies [Formula: see text] and angular quantum numbers [Formula: see text], are then obtained by numerically solving the resultant homogeneous matrix equation. This work shows that the present approach is an accurate, as well as efficient method for investigating quasinormal modes.