- buyTicket: Buy lottery tickets and pay a fee to the contract manager
- The user's deposit amount should not be less than the ticket price
- The time to participate in the lottery is not over.
- startLottery: Lottery by the manager and deposit the winning amount
- Only the administrator has access to this function.
- The time to participate in the lottery is over.
- This function has not been performed before.
- Random: Generate a random number of available ticket numbers
samankeighobadi / lottery Goto Github PK
View Code? Open in Web Editor NEWBlockchain-based smart lottery contract