start addition of nearest neighbor algo