← Salesforce questions

Find city with maximum distance to nearest station

Filed under Salesforce

Given a sorted list of cities and stations on a positive x-axis, find the city such that the distance between the city and its nearest station is maximized.

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Salesforce questions

Collected from public candidate posts and coding forums. Updated Nov 2026.