IXL Learning Interview Question

Just one algorithms question