Nearest neighbor classifier on a simple dataset

23 Views Asked by At

Consider the following data set for two classes $X_1 = \{ (0,0) \}, X_2 = \{(1,0),(0,1)\}$

I'm trying to come up with a rule to separate the data using k-nn for $k = 1$. But I don't know how to apply the k-nn algorithm on this data set. Can anyone help?