Answer: Choice D
The input x = 1 leads to multiple outputs y = 1 and y = 2 simultaneously, which is why choice D isn't a function.
A function is only possible if any input leads to exactly one output only. Choices A,B and C are all functions for this reason.