Answer: $240
The reason why is because the friend charges $30 a car and has fees of $15/hour. So you multiply the $30 by the amount of cars, which is 12. You get $360. Then, you multiply the fees ($15) by the amount of hours (8) to get $120. You take the money you earn, which is $360, and subtract it by the total fees, which is $120. $360-$120=$240.
Hope this helps! :D