Unweighted: via max flow

Build graph: source → workers → jobs → sink. All capacities = 1. Max flow = max matching.

Advertisement

Hopcroft-Karp

Faster bipartite matching: O(E × sqrt(V)). Uses augmenting paths in BFS layers.

Advertisement

Hungarian algorithm

For weighted bipartite matching (assignment). O(V³). Finds min-cost perfect matching.