Answer :
Let's take those 6 squashes. You get 98-6*3=80. Now you have an identical number of pumpkins and squashes. A pumpkin and a squash are sold, in total, for $8, so to get $80 you need 10 of each. You have 10 pumpkins and 10+6=16 squashes.