Half of $46.18 is $23.09. Then if he bought two donuts and each donut cost $0.75 then you plus $0.75 + $0.75 = 1.5. You then minus $ 1.5 from your current $23.09 dollars, which will equal $21.59. You have to minus the coffe amount which will is $2.99 . You minus $21.59 - $2.99 =$18.6.
He then gives half of his money to his brother (so divide starting money by 2)
46.18 / 2 = 23.09
He now has $23.09
He then buys two donuts for $0.75 each ( 0.75 * 2 = 1.50 ) and a cup of coffee for $2.99 ( so he spent a total of 4.49 ) so we then subtract 4.49 from 23.09