The revenue from selling x hats is r(x) = 18x.
The cost of buying x hats is c(x) = 8x+ 30.
The profit from selling x hats is p(x) = r(x) - c(x).
Write a function for p(x), the profit from selling x hats.
A. p(x) = 10x - 30
B. p(x) = 26x + 30
C. p(x) = 26x - 30
D. p(x) = 10x + 30