Gale-Shapley algorithm


O(N)O(N)
O(N2)O(N^2)
👉

>G-S (1) 1 2 (2) (3)