Skip to content

Commit c35ac0c

Browse files
committed
Finished mandatory debug
1 parent b286998 commit c35ac0c

File tree

1 file changed

+5
-2
lines changed
  • Sprint-2/2-mandatory-debug

1 file changed

+5
-2
lines changed

Sprint-2/2-mandatory-debug/0.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,17 @@
11
// Predict and explain first...
22

3-
// =============> write your prediction here
3+
// =============> write your prediction here: The function does not return any value so instead of 320 being printed, undefined will be printed instead.
44

55
function multiply(a, b) {
66
console.log(a * b);
77
}
88

99
console.log(`The result of multiplying 10 and 32 is ${multiply(10, 32)}`);
1010

11-
// =============> write your explanation here
11+
// =============> write your explanation here: It is a logic error as it prints out an unexpected value, undefined.
1212

1313
// Finally, correct the code to fix the problem
1414
// =============> write your new code here
15+
//function multiply(a, b) {
16+
// return a * b;
17+
//}

0 commit comments

Comments
 (0)