The combined total dollar amount Mary pays is the sum of the amount she pays at Westside and Pinewood, like this:
total amount = Westside amount + Pinewood amount
The amount she pays at each college is given by particular class fees multiplied by the number of hours she studies at each college. Class fees for Westside are $98 and w are the credits hours at this college. Class fees at Pinewood are $115 and p are the credit hours at this college, then we can rewrite the above equation like this:
total amount = 98w + 115p
We are told that she is taking a combined total of 15 credit hours, then when we sum up the credit hours at Westside and Pinewood we ge 15, like this:
w + p = 15
From this expression we can solve for p to get:
p = 15 - w
By replacing 15 - w for p into the above equation we get:
total amount = 98w + 115×(15 - w)
We can simplify this expression to get:
total amount = 98w + 115×25 - 115×w
total amount = 98w - 115w + 2875
total amount = -17w + 2875
Then, we can calculate the combined total dollar amount she paid for her class fees with the expression total amount = -17w + 2875