We want maximum profit, which is the max value of y.
We basically want for which x value, we have y as the maximum.
First,
let's take the derivative of y:
[tex]\begin{gathered} y=-x^2+101x-900 \\ y^{\prime}=-2x+101 \end{gathered}[/tex]Maximum is when the derivative is equal to 0. So, the x-value when derivative is 0:
[tex]\begin{gathered} y^{\prime}=-2x+101 \\ 0=-2x+101 \\ 2x=101 \\ x=\frac{101}{2} \\ x=50.5 \end{gathered}[/tex]To get max profit, the widgets should be sold at $50.50