Citadel interview question

Implement the k nearest neighbour algorith.