Ad
  • Custom User Avatar

    I would gladly accept the proper grammar description.Feel free to provide one.

    Cheers!

  • Custom User Avatar

    Yea, is there a reviewer before questions get submitted?

  • Custom User Avatar

    I don't like the variable names in JavaScript for the function, it makes things very unclear.

    function rolldiceSumProb(arr, totalSides){ ...

    I don't know what arr means and totalSides confuses the number of dice with the number of sides each dice have. It took me awhile to realize that it meant totalDice, and even then the name "totalSides" is not good for programming.

    I recommend changing the functon name to function rolldiceSumProb(sum, numDice){ // Each die has 6-sides...
    With this the programmer can understand exactly what is expected and what the function should do at a glance.

  • Custom User Avatar