Lyft Interview Question

remove the given C++ code bugs and warnings, solve some algorithm problems.