The graph of a linear function g has a slope of −2 and a y-intercept of 5. Which of the following defines g?
g(x)=−2x+5
g(x)=2x+5
g(x)=−2x−5
g(x)=5x−2