S&P Global Interview Question

Coalesce implementation