As, we know - product of eigenvalues of a matrix is equal to determinant of that matrix.
so,
(-1) × 7
= det(A)
=(1 × a ) - (4 × b)
so, a - 4b = -7 -------(1)
also, trace (sum of the diagonal elements) of a matrix is equal to sum of eigenvalues of the matrix.
so, 1 + a = -1+7 =6
so, a = 5 -------(2)
from equation (1) and (2)
b = 3
So,answer is D