Back to problems

Validate Lat/Long With Minimum Expensive API Calls

Object-Oriented Programming · Microsoft · Medium

Requirements A large CSV file contains rows with name, address, city, state, zip, lat, long. You can query an external, paid geocode(address, city, state, zip) -> (lat, long) service. Determine whether each saved (lat, long) agrees with the value that geocode() would produce, while spending as little as possible on API requests over the entire file. Preparation Rehearse presenting the sequence clearly: caching → batching → coarse screening → paid lookup. Interviewers…

Checking your access…