Created
December 13, 2016 21:04
-
-
Save DavidGinzberg/0fcf4bc32b67b56c4c78485023598fd4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Each of these functions has something wrong with it. Why won't it work and how can it be fixed? | |
//Produces the product of all numbers in an array | |
function product(numbers){ | |
var result = 0; | |
for(var i = 0; i < numbers.length; i++){ | |
result *= numbers[i]; | |
} | |
return result; | |
} | |
//more to come |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment