Skip to content

LottoApp is an application that calculates the time to find a random lottery ticket that matches the user's ticket.

Notifications You must be signed in to change notification settings

pumppituntti/LottoApp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 

Repository files navigation

LottoApp

Usually people think that only a lucky can win the lottery, but for an ordinary person a whole life is not enough to find that lucky ticket. Fortunately, now you don't have to wait a lifetime to try your luck, because now there is the LottoApp!

Description

LottoApp is a Java application that calculates the time to find a random lottery ticket that matches the user's ticket, provided that the user would buy one ticket per week.

How to use

To use the application, just run the Lotto file in the terminal. At startup, the program asks the user to enter 7 unique numbers from 1 to 40.

When entering an incorrect number or symbol, the program asks to enter the number again.

When 7 numbers are entered, the program starts looking for random tickets with matching numbers.

The time spent on the search is considered, at the rate of one ticket per week.

Features

The program has the ability to change the number of digits in the lottery ticket (default 7) and the range of acceptable values in the ticket (default 40). To do this, you need to change the value of the variables (ArraySize and ArrayMax) in the Lotto class.

About

LottoApp is an application that calculates the time to find a random lottery ticket that matches the user's ticket.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published