+ 1

what is the bug of the following program?

function multiply (a,b) { return a*b }

25th Jul 2017, 5:43 AM
Md. Jahid Hasan
Md. Jahid Hasan - avatar
2 Answers
+ 3
A semicolone is required after your "return" return a*b; <- there :D
25th Jul 2017, 5:52 AM
Geoffrey L
Geoffrey L - avatar
+ 3
You're also missing the $ before all of the variables. function multiply($a, $b) { return $a * $b; }
25th Jul 2017, 6:44 AM
ChaoticDawg
ChaoticDawg - avatar