------
## 最终结论
```python
from collections import defaultdict, deque

def numBusesToDestination(routes, S, T):
    if S == T:
        return 0

    # Step 1: Create a mapping from bus stops to the routes that pass through them
    stop_to_routes = defaultdict(set)
    for i, route in enumerate(routes):
        for stop in route:
            stop_to_routes[stop].add(i)

    # Step 2: Use BFS to find the least number of buses to reach destination
    queue = deque([S])
    visited_stops = set([S])
    visited_routes = set()
    buses_taken = 0

    while queue:
        buses_taken += 1
        for _ in range(len(queue)):
            current_stop = queue.popleft()
            for route_index in stop_to_routes[current_stop]:
                if route_index in visited_routes:
                    continue
                visited_routes.add(route_index)
                for next_stop in routes[route_index]:
                    if next_stop == T:
                        return buses_taken
                    if next_stop not in visited_stops:
                        visited_stops.add(next_stop)
                        queue.append(next_stop)

    return -1
```