Potential solution
Added comments