Sigma Computing interview question

write a function to find needle in a haystack