



"""simple docstring"""







from __future__ import annotations


def  __SCREAMING_SNAKE_CASE (  __UpperCAmelCase   ,				__UpperCAmelCase      ):
		assert len(__UpperCAmelCase      ) == len(__UpperCAmelCase      )

		_lowercase				: List[Any]     =   len(__UpperCAmelCase      )
		_lowercase				: List[Any]     =   list(range(__UpperCAmelCase      )      )
		_lowercase				: Any     =   [-1] * n  # who the donor has donated to
		_lowercase				: str     =   [-1] * n  # who the recipient has received from
		_lowercase				: Optional[int]     =   [0] * n

		while unmatched_donors:
				_lowercase				: Optional[int]     =   unmatched_donors[0]
				_lowercase				: Tuple     =   donor_pref[donor]
				_lowercase				: int     =   donor_preference[num_donations[donor]]
				num_donations[donor] += 1
				_lowercase				: List[str]     =   recipient_pref[recipient]
				_lowercase				: Optional[int]     =   rec_record[recipient]

				if prev_donor != -1:
						if rec_preference.index(__UpperCAmelCase      ) > rec_preference.index(__UpperCAmelCase      ):
								_lowercase				: Tuple     =   donor
								_lowercase				: Any     =   recipient
								unmatched_donors.append(__UpperCAmelCase      )
								unmatched_donors.remove(__UpperCAmelCase      )
				else:
						_lowercase				: Tuple     =   donor
						_lowercase				: Union[str, Any]     =   recipient
						unmatched_donors.remove(__UpperCAmelCase      )
		return donor_record








"""simple docstring"""







from math import factorial


def  __SCREAMING_SNAKE_CASE (  __UpperCAmelCase   ,				__UpperCAmelCase      ):
		return factorial(__UpperCAmelCase      ) / (factorial(__UpperCAmelCase      ) * factorial(n - r      ))


def  __SCREAMING_SNAKE_CASE (  ):
		_lowercase				: Optional[Any]     =   0

		for i in range(1   ,				101      ):
				for j in range(1   ,				i + 1      ):
						if combinations(__UpperCAmelCase   ,				__UpperCAmelCase      ) > 1E6:
								total += 1
		return total


if __name__ == "__main__":
		print(solution())



