AdvancedAlgorithms.StableMarriage2.DoMatching C# (CSharp) Method

DoMatching() public static method

public static DoMatching ( Person men, Person women, int numPairs ) : void
men Person
women Person
numPairs int
return void
        public static void DoMatching(Person[] men, Person[] women, int numPairs)
        {
            for (int i =0 ;i < numPairs; i++)
            {
                Person m = men[i];
                while (!m.IsMatched())
                {
                    m = FindMatch(m);
                }
            }
        }