Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
finished 2.4 and 2.5
  • Loading branch information
jshortz committed Jul 13, 2019
commit 8098ebc1a2625d41c19d57ecb80ab7f773600ee2
4 changes: 3 additions & 1 deletion Week3/homework/step2-4.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
'use strict';

function Dog() {
// add your code here
this.name = 'Fido';
this.color = 'white and brown';
this.numLegs = 4;
}

const hound = new Dog();
Expand Down
7 changes: 5 additions & 2 deletions Week3/homework/step2-5.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,11 @@ function multiplyAll(arr) {
// eslint-disable-next-line
let product = 1;

// Replace this comment and the next line with your code
console.log(arr, product);
for (let i = 0; i < arr.length; i++) {
for (let j = 0; j < arr[i].length; j++) {
product = product * arr[i][j];
}
}

return product;
}
Expand Down