0
Why number() method is not working in this code
5 Respostas
+ 1
Number(a) +d
+ 4
Write Number(a) +d . //a is a string here and d is a number , whenever javascript sees a number and a string it concatenates them instead of adding.
When you do a+Number(d) you add a string(a) and a number (d) and yes d is already a number , no need to convert it to a Number again!
+ 3
let e = Number(a) + d;
0
Code not working
0
But this is not working. It's behave like a string