[C++] 2 lines, 1 pass
\nclass Solution {\npublic:\n    int distanceBetweenBusStops(vector<int>& b, int s, int e) {\n        if (e < s) swap(e, s);\n        return min(reduce(begin(b)
```\nclass Solution {\npublic:\n    int distanceBetweenBusStops(vector<int>& b, int s, int e) {\n        if (e < s) swap(e, s);\n        return min(reduce(begin(b) + s, begin(b) + e), reduce(begin(b), begin(b) + s) + reduce(begin(b) + e, end(b)));\n    }\n};\n```
[]