Answer :
Firstly, you should work out the cost that he paid. He paid 12 (a dozen) by $8. Therefore, he paid $96 for the pens. In total, he has 288 pens (12x24). In total, he split 5 lots of 24, which is 120. You should then divide this by 6 (as he split them into packs of 6). 120/6= 20. He sold 20 pack at $3, for a total cost of $60. As he then split the rest 288-120= 168 for three pens. You then have to divide 168/3, giving you 56. As he sold these at $2 a pack, you have to multiply $2 by 56, giving you $112.
Add together $112 and $60, and this gives you $172. To find the profit, subtract the total cost $96 from the total turnover $172. $172-$96= $76.
Therefore, the total profit made is $76.
Hope this helps :)