File tree Expand file tree Collapse file tree 1 file changed +6
-7
lines changed
Sprint-2/2-mandatory-debug Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Original file line number Diff line number Diff line change 44// The program will print 320 first.
55// Then it will " The result of mutiplying 10 and 32 is 320".
66
7-
87function multiply ( a , b ) {
98 console . log ( a * b ) ;
109}
@@ -14,14 +13,14 @@ console.log(`The result of multiplying 10 and 32 is ${multiply(10, 32)}`);
1413// =============> write your explanation here
1514// The function multiply is used console.log(a * b) to show the result
1615// however, it does not resturn the value .
17- // when the function is used inside the sentence with ${multiply(10, 32)}
16+ // when the function is used inside the sentence with ${multiply(10, 32)}
1817// JavaScript expects the function to give back a value.
1918//Becuse the function does not return anything, the result becomes undefined.
2019
2120// Finally, correct the code to fix the problem
2221// =============> write your new code here
23- function multiply ( a , b ) {
24- return a * b ;
25- }
26-
27- console . log ( `The result of multiplying 10 and 32 is ${ multiply ( 10 , 32 ) } ` ) ;
22+ function multiply ( a , b ) {
23+ return a * b ;
24+ }
25+
26+ console . log ( `The result of multiplying 10 and 32 is ${ multiply ( 10 , 32 ) } ` ) ;
You can’t perform that action at this time.
0 commit comments