A lottery is a game with low odds where winnings are chosen through a random…