Skip to content
Prev Previous commit
Next Next commit
Changed the function to loop thru 10 to 15 values
  • Loading branch information
Radhikajram committed Jul 29, 2019
commit 97f9304fab2e92bfff3de79670f3695e37fe5c47
5 changes: 4 additions & 1 deletion Week3/homework/step2-2.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
'use strict';

function threeFive(startIndex, stopIndex, threeCallback, fiveCallback) {
const numbers = [startIndex, stopIndex];
const numbers = [];

for (let i = startIndex; i < stopIndex + 1; i++) {
numbers.push(i);
}
// Replace this comment and the next line with your code
for (const i of numbers) {
if (typeof threeCallback !== 'undefined' && i % 3 === 0) {
Expand Down