Sammy went to the candy store on Monday, bought 12 ounces of candy, and saw that the total was $7.80. Sammy went again to the store on Wednesday, bought 9 ounces of candy, and saw that the total was $5.85. Write an equation for the cost of candy using function notation:f(x). Find the average cost of one ounce of candy.