# How do you graph the function y=5x-x^2?

First you realise that $5 x - {x}^{2} = x \left(5 - x\right)$ which will give the
$y = 0$ solutions $x = 0$ and $x = 5$ for $\left(0 , 0\right)$ and $\left(5 , 0\right)$
Then, put the halfway-$x$ ($2.5$) in the equation to get the top of the graph $y = 5 \cdot 2.5 - {2.5}^{2} = 6.25$ for $\left(2.5 , 6.25\right)$
You now have the three most important points of your graph. You can put more $x$-values in, of course, so you get more points, but these three are essential.