- Step 1: Select the number K of the neighbors
- Step 2:Calculate the Euclidean distance of K number of neighbors
- step-3:Take the K nearest neighbors as per the calculated Euclidean distance
-step-4:Among these k neighbors, count the number of the data points in each category.