WE ALWAYS WANT PEOPLE TO ASK WHEN THEY DO NOT UNDERSTAND. :)
Thank you for asking anon :)
I have used the formula
$$FV = PV*(1+i)^n$$
where FV is furure value
FV = $5000
PV is present value
PV = ? This is what we need to find
i is the interest rate per compounding period
i= 4% = 0.04 and this is yearly
n is the number of compounding periods
n =10 because it is 10 years
so
$$\\5000=PV(1+0.04)^{10}\\\\
5000=PV*(1.04)^{10}\\\\
$You need to divide both sides by $1.04^{10} $ to get the PV by itself$\\\\
PV= 5000\div(1.04)^{10}\\\\$$
$${\frac{{\mathtt{5\,000}}}{{{\mathtt{1.04}}}^{{\mathtt{10}}}}} = {\mathtt{3\,377.820\: \!844\: \!128\: \!994\: \!282\: \!6}}$$
you will need to invest $3377.82
Now let me know if you do not understand and try to explain which bit is giving you problems. :)