Spire Global Interview Question

easy-medium leetcode problem mostly around data cleaning and quering