think-cell interview question

Solving a few DSA/C++ knowledge problems