This is project "Brain Games" on the Python Development course on Hexlet.io
This project was built using these tools:
Tool | Description |
---|---|
poetry | "Python dependency management and packaging made easy" |
Py.Test | "A mature full-featured Python testing tool" |
wemake-python-styleguide | "the strictest and most opinionated python linter ever" |
git clone https://github.com/AndryVanDuk/python-project-49.git
cd python-project-49
make package-install
"Mind Games" is a set of five console games based on the popular mobile brain-pumping apps. Each game asks questions that need to be answered correctly. After three correct answers, the game is considered completed. Incorrect answers end the game and prompt you to play it again.
Games:
- Brain Even (Answer "yes" if the number is even, otherwise answer "no")
- Brain Calculator (Answer what is the result of the expression?)
- Brain GCD (Answer what is the greatest common divisor of given numbers)
- Brain Progression (Answer what number is missing in the progression?)
- Brain Prime (Answer "yes" if given number is prime, otherwise answer "no")
They are launched with simple commands:*
brain-even
brain-calc
brain-gcd
brain-progression
brain-prime
โ๏ธ*Make sure that you have Python version 3.6 or higher installed.
The essence of the game is as follows: the user is shown a random number. And he needs to answer 'yes' if the number is even, or 'no' if it is odd:
The essence of the game is as follows: the user is shown a random mathematical expression that needs to be calculated and written down the correct answer.
The essence of the game is as follows: the user shows two random numbers, for example, 25 50. The user must calculate and introduce the largest total divider of these numbers.
The essence of the game is as follows: the user is shown a series of numbers, forming an arithmetic progression, replacing any of the numbers with two dots. The player must determine this number.
The essence of the game is as follows: the user is shown a random number. And he needs to answer "yes" if the number is prime, or "no" if it is composite: