MathWorks interview question

coding involving bit manipulation, recursion.