This sort of interview is insulting. There are real problems to solve in business and elegant solutions to the 'next number in sequence' isn't one of them.
"Yesterday I went to a job interview, at a company in New York that had once built their stack (for managing online advertising) in Ruby but who are now transitioning all of their stuff to Clojure."
I would have probably walked out or at least snarkily asked them if these types of algorithms are what's done day to day. The answer more than likely being no.
There's not really time in a 30 minute interview to pose a real business problem, much less have any meaningful representative work done, by which to judge the candidate.