PHPackages                             alexp11223/brain-games - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. alexp11223/brain-games

ActiveProject

alexp11223/brain-games
======================

hexlet.io project 1

0.7.7(6y ago)128MITPHP

Since Jul 2Pushed 6y agoCompare

[ Source](https://github.com/AlexP11223/php-project-lvl1)[ Packagist](https://packagist.org/packages/alexp11223/brain-games)[ Docs](https://github.com/AlexP11223/php-project-lvl1)[ RSS](/packages/alexp11223-brain-games/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (2)Versions (16)Used By (0)

[![Maintainability](https://camo.githubusercontent.com/f274179768b61895daa8860bdd02c698c69668a898e6216b86dc8ea8a6ccfe46/68747470733a2f2f6170692e636f6465636c696d6174652e636f6d2f76312f6261646765732f34363864346665303830653566353935623866372f6d61696e7461696e6162696c697479)](https://codeclimate.com/github/AlexP11223/php-project-lvl1/maintainability)[![Build Status](https://camo.githubusercontent.com/d5de368e13af6bd18329393e34957ee2bd04a83605bdab34486c0d867f353d99/68747470733a2f2f7472617669732d63692e6f72672f416c65785031313232332f7068702d70726f6a6563742d6c766c312e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/AlexP11223/php-project-lvl1)

Brain Games
===========

[](#brain-games)

Small logic games involving basic arithmetical operations and number properties. Each game consists of up to 3 rounds.

This is an educational project implemented during  courses aimed at setting up the environment, getting familiar with some best practices and creating a good simple architecture.

Installation
------------

[](#installation)

- Install PHP 7.2+ and [Composer](https://getcomposer.org/doc/00-intro.md#globally).
- Run `composer global require alexp11223/brain-games`.
- Make sure that the Composer global bin dir (`composer global config bin-dir --absolute`) is in your `PATH`.

[![asciicast](https://camo.githubusercontent.com/49a5532ab6c8eef9558f769e14a631abafacede4c0dbeff81ac447fa95799229/68747470733a2f2f61736369696e656d612e6f72672f612f515647354e416954503357596e4d717351664659796679544c2e737667)](https://asciinema.org/a/QVG5NAiTP3WYnMqsQfFYyfyTL)

Usage
-----

[](#usage)

Run the following games:

- `brain-even`
- `brain-calc`
- `brain-gcd`
- `brain-progression`
- `brain-prime`

### brain-even

[](#brain-even)

Answer whether the given number is even.

[![asciicast](https://camo.githubusercontent.com/aa6080c2d8fc9862ccdbb7d65bf7f161bb70aeb6b08c754a17c5830dece31921/68747470733a2f2f61736369696e656d612e6f72672f612f7a4c324571595561426264306d5175596164584d39446b364c2e737667)](https://asciinema.org/a/zL2EqYUaBbd0mQuYadXM9Dk6L)

### brain-calc

[](#brain-calc)

Enter the result of the arithmetic expression.

[![asciicast](https://camo.githubusercontent.com/63e8d114766fd2ef899eea50c74c647768e2c2b4a49c170d587d07ef222f2447/68747470733a2f2f61736369696e656d612e6f72672f612f6f4f5070354f697a59523831494a30393936624d6b4b4344742e737667)](https://asciinema.org/a/oOPp5OizYR81IJ0996bMkKCDt)

### brain-gcd

[](#brain-gcd)

Find the greatest common divisor of two numbers.

[![asciicast](https://camo.githubusercontent.com/cf573f916f497f8a8e1d9cbd4d6e687bac545df07a13e288a4e2c7d47998b927/68747470733a2f2f61736369696e656d612e6f72672f612f434f6e6638746f6a53496a6a6730654259634a4c57747438472e737667)](https://asciinema.org/a/COnf8tojSIjjg0eBYcJLWtt8G)

### brain-progression

[](#brain-progression)

Enter the number missing in the arithmetic progression.

[![asciicast](https://camo.githubusercontent.com/02be9c2ac82f36fe24a2eb6fd710bd28bc02ad889e681caff7ea042e8043cab1/68747470733a2f2f61736369696e656d612e6f72672f612f5a3249753078616b3451593955557a7063756e7667663278452e737667)](https://asciinema.org/a/Z2Iu0xak4QY9UUzpcunvgf2xE)

### brain-prime

[](#brain-prime)

Answer whether the given number is prime.

[![asciicast](https://camo.githubusercontent.com/86b93a5d9f9229bf5467f6aaf849ca9bdefc5681cf98e9bb0280461d2bc3d495/68747470733a2f2f61736369696e656d612e6f72672f612f676465494e5759616a696b446257654959767a7152453549372e737667)](https://asciinema.org/a/gdeINWYajikDbWeIYvzqRE5I7)

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~2 days

Total

14

Last Release

2475d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/16bd69552168e7711b45d9b95ba92d6ffa82489c010e351c52dcd3477ee07050?d=identicon)[AlexP11223](/maintainers/AlexP11223)

---

Top Contributors

[![AlexP11223](https://avatars.githubusercontent.com/u/5680466?v=4)](https://github.com/AlexP11223 "AlexP11223 (61 commits)")

---

Tags

composereducationalhexlethexlet-projectslogic-gamephpeducationgame

###  Code Quality

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/alexp11223-brain-games/health.svg)

```
[![Health](https://phpackages.com/badges/alexp11223-brain-games/health.svg)](https://phpackages.com/packages/alexp11223-brain-games)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
