A carnival charges $5 to get in, plus $2 per ride. Which equation represents the relationship between the number of carnival rides a person rides x and the cost of attending the carnival y.
x= 2x+5


y= 2x-5


y= 2x+5


y= 5-2x