File tree Expand file tree Collapse file tree 4 files changed +9
-9
lines changed Expand file tree Collapse file tree 4 files changed +9
-9
lines changed Original file line number Diff line number Diff line change 11#!/usr/bin/env node
22
3- import runBrainEvenGame from '../src/games/even.js'
3+ import runEvenGame from '../src/games/even.js'
44
5- runBrainEvenGame ( )
5+ runEvenGame ( )
Original file line number Diff line number Diff line change 11import readlineSync from 'readline-sync'
22
3- export default function runBrainGames ( ) {
3+ const greetingBrainGames = ( ) => {
44 console . log ( 'Welcome to the Brain Games!' )
55 const name = readlineSync . question ( 'May I have your name? ' )
66 console . log ( `Hello, ${ name } !` )
77}
8+
9+ export default greetingBrainGames
Original file line number Diff line number Diff line change @@ -26,6 +26,6 @@ const getRound = () => {
2626 return [ question , correctAnswer ]
2727}
2828
29- export default function playGcd ( ) {
30- runEngine ( rule , getRound )
31- }
29+ const playGcd = ( ) => runEngine ( rule , getRound )
30+
31+ export default playGcd
Original file line number Diff line number Diff line change 1- const getRandomNumber = ( min , max ) => {
1+ export const getRandomNumber = ( min , max ) => {
22 // NOSONAR
33 return Math . floor ( Math . random ( ) * ( max - min + 1 ) ) + min
44}
5-
6- export default getRandomNumber
You can’t perform that action at this time.
0 commit comments