There are many ways to approach the stable marriage problem. Youare to implement a specific algorithm described below. This is thebasic outline: set each person to be free; while (some man m with anonempty preference list is free) { w = first woman on m’s list; if(some man p is engaged to w) { set p to be free } set m and w to beengaged to each other for (each successor q of m on w’s list) {delete w from q’s preference list delete q from w’s preference list} } Consider, for example, the following short input: Man 0:
PayPal Gateway not configured
PayPal Gateway not configured