Are you familiar with finding the min or max of a function by setting its derivative equal to zero? Here you have E = 10000p-100p^2, so dE/dp = 10000-500p. Set this equal to zero, solve for p, and check that the result is a max and not a min by seeing if d^2E/dp^2 is positive or negative.

If you are not famiiar with calculus you can try plotting the graph for E=10000p-100p^2 and see if you can estimate what value of p makes E the largest.