Let \(k=\) Kevin's age
Let \(d=\) Daniel's age
We know
\(k=3d\)
and
\(k-4=5(d-4)\)
Plug the value of \(k\) into the second equation:
\(3d-4=5(d-4)\)
\(\rightarrow3d-4=5d-20\)
\(\rightarrow-2d-4=-20\)
\(\rightarrow-2d=-16\)
\(\rightarrow d=8\)
So Daniel is 8 years old.