Choice A is not a function because x = 2 leads to more than one y value (y = 1 and y = 7 at the same time)
Choice B is not a function for similar reasoning. Here we have x = 1 lead to y = 2 and y = 5 simultaneously.
Choice D is also not a function because of the two points (5,2) and (5,4). This tells us we have x = 5 lead to y = 2 and y = 4 at the same time.
A function is only possible if you have any input lead to exactly one output. Choice C shows this. Note how it passes the vertical line test. It is impossible to draw a vertical line through more than two points on the function curve.