Set from 5 console games:
Before installing you need to required in install of Node.js and NPM. Check in your console next command:
$ node -v
and
$ npm -v
you must have version for Node.js (example v13.7.0
) and NPM (example 6.13.7
). If you don't, make next steps.
Installing Node.js by typing:
$ [sudo] apt install nodejs -g
//atribute "-g" means global
or download binaries and check $ node -v
in console.
Download installer and install this distributive and check $ node -v
in console.
NPM must be installed with Node.js, but
- Choose directory for installing binaries and make next: *recomended
$ npm install git+ssh://[email protected]:Sinoptik93/frontend-project-lvl1.git
or without SSH:
$ npm instal git+https://github.com/Sinoptik93/frontend-project-lvl1
- next make binaries links in system
$ npm link
you must get the following lines:
frontend-project-lvl1$ npm link
audited 474 packages in 5.09s
17 packages are looking for funding
run `npm fund` for details
found 0 vulnerabilities
/usr/local/bin/brain-calc -> /usr/local/lib/node_modules/brain-games-jan2020/bin/brain-calc.js
/usr/local/bin/brain-even -> /usr/local/lib/node_modules/brain-games-jan2020/bin/brain-even.js
/usr/local/bin/brain-gcd -> /usr/local/lib/node_modules/brain-games-jan2020/bin/brain-gcd.js
/usr/local/bin/brain-progression -> /usr/local/lib/node_modules/brain-games-jan2020/bin/brain-progression.js
/usr/local/bin/brain-prime -> /usr/local/lib/node_modules/brain-games-jan2020/bin/brain-prime.js
/usr/local/bin/brain-games -> /usr/local/lib/node_modules/brain-games-jan2020/bin/brain-games.js
/usr/local/lib/node_modules/brain-games-jan2020 -> /home/sinner/git/Hexlet/frontend-project-lvl1
- installing with
npm publish
:
Your target - is to determine the random number: even or not.
*You can adjust the difficulty by changing the configuration parameters in src/games/even.js
-> Section // CONFIGURATION //
Input next command to launch game:
$ brain-even
Remember school arithmetic and show your brilliant knowledges by counting random expressions!
*You can adjust the difficulty by changing the configuration parameters in src/games/calc.js
-> Section // CONFIGURATION //
$ brain-calc
Find the greatest common divisor for two random numbers.
*You can adjust the difficulty by changing the configuration parameters in src/games/gcd.js
-> Section // CONFIGURATION //
$ brain-gcd
Write a missing number in increasing progression.
*You can adjust the difficulty by changing the configuration parameters in src/games/progression.js
-> Section // CONFIGURATION //
$ brain-progression
You need to answer the question: is the current random number prime?
*You can adjust the difficulty by changing the configuration parameters in src/games/prime.js
-> Section // CONFIGURATION //
$ brain-prime