scrimba
Create an RPG game - Rob Sutcliffe
Get Percentage
Go Pro!Bootcamp

Bootcamp

Study group

Collaborate with peers in your dedicated #study-group channel.

Code reviews

Submit projects for review using the /review command in your #code-reviews channel

Get Percentage
by
AboutCommentsNotes
Get Percentage
by
Expand for more info
utils.js
run
preview
console

const getPercentage = (num, total) => 0;

// we should console log out 30%
console.log(`${getPercentage(60,200)}%`);

const getDiceRollArray = (diceCount) =>
new Array(diceCount).fill(1).map(() =>
Math.floor(Math.random() * 6) + 1
);

const sumArray = arr => arr.reduce((acc, curr) => acc + curr, 0);

export { getDiceRollArray, sumArray }
Console
"0%"
,
/index.html
-1:35