Pass an array and a value, get back the closest number.