To be a function each different x value would have a different Y value.
First one is a function, there are no repeated Y values.
The second one is a function.
Third one is not a function because it has two identical Y values with different x values.
The fourth one is a function.