Let a be the first term and d be the common difference of the arithmetic sequence.
\(\begin{cases} (a + d) + (a + 7d) = 5\\ (a + 3d)(a + 4d) = 5 \end{cases}\)
\(\begin{cases} a = \dfrac{5 - 8d}{2}\\ (a + 3d)(a + 4d) = 5 \end{cases}\)
Now you can substitute the first equation into the second, and solve the resulting quadratic equation for the value(s) of d.
Then you will also be able to find the corresponding value(s) of a.
The answer is a + 19d, but please calculate the value(s) of a and d and substitute to get the numerical answer.