
Carol H. answered 02/14/19
Masters' Degree in Mathematics with 35 years of Teaching Experience
Let p = the number of pies sold
Let c = the number of cakes sold
c + p = 40 c = 40 - p
10p + 8c = 365
10p + 8(40 - p) = 365
10p + 320 - 8p = 365
2p = 45
p = 22 1/2 pies
c = 40 - p
c = 40 - 22 1/2
c = 17 1/2 cakes
Evidently, one can buy half a cake or pie.