Ab Initio interview question

A walkthrough with an engineering over coding problems