A lottery is a game in which players pay a small sum of money for…