filmov
tv
Leetcode solving: 1184. Distance Between Bus Stops

Показать описание
A bus has n stops numbered from 0 to n - 1 that form a circle. We know the distance between all pairs of neighboring stops where distance[i] is the distance between the stops number i and (i + 1) % n.
The bus goes along both directions i.e. clockwise and counterclockwise.
Return the shortest distance between the given start and destination stops.
####################################
Please subscribe to my channel
My other Leetcode solving videos (easy)
Leetcode solving videos (Medium):
Leetcode solving videos (Hard):
The bus goes along both directions i.e. clockwise and counterclockwise.
Return the shortest distance between the given start and destination stops.
####################################
Please subscribe to my channel
My other Leetcode solving videos (easy)
Leetcode solving videos (Medium):
Leetcode solving videos (Hard):