We can remember that a function is a relation between two variables in such a way that the independent variable has EXACTLY one dependent variable.
In this case, we have that:
a ---> 0
b ---> 1
c ---> 0
d ---> 1
We do not find that the variable has other value. It has only a value of 0.
It does not matter that the other values have the same output.
Thus, this information 'tells us' that the relation is a function.
Additionally, the domain of the function, in this case, are all the elements in the input row, that is:
Domain: {a, b, c, d}