This problem is best done using conservation of energy methods.
There will be three terms in the expression, as there are three different energy changes that occur - kinetic, potential and frictional heating (shown in that order in the equations below).
Using the symbols given in the problem
where the middle term for the potential energy is subtracted because this will be an energy decrease.
We now rearrange the make
Multiply each term by 2 and divide each by