Regular bipartite graph has a perfect matching (source code)

= Regular bipartite graph has a perfect matching

In a $k$-regular bipartite graph, edge counting gives equal vertex-class sizes and $k|S|\leq k|N(S)|$. Hall's theorem therefore supplies a perfect matching.