6 cakes and 5 pies were sold

This looks like a job for a substitution with a system of two equations and two unknowns

Let x = cakes

Let y = pies

Equation 1 can represent total baked goods sold

x + y = 11

Equation 2 can represent total cost $145

15x + 11y = 145

Equation 1 is ideal for setting up a substitution

x + y = 11

AND

y = 11 - x

We will use this quantity for y in Equation 2

15x + 11y = 145

15x + 11(11 - x) = 145

15x + 121 - 11x = 145

Combine like terms

15x - 11x + 121 = 145

4x + 121 = 145

Subtract 121 from both sides of the equation

4x = 145 - 121

4x = 24

Divide both sides by 4

x = 6

We already know from Equation 1

y = 11 -x

y = 11 - 6

y = 5

We use our values in both equations to check

x + y = 11

6 + 5 = 11

15(6) + 11(5) = 145

90 + 55 + 145

145 = 145

Of course you can do this by elimination as another means of checking give it a try.

I hope you find this information useful.

Send me an email if you have any questions.