+ 3
Could someone explain me how this code works line to line? Thanks.
var X=10; var x=7; var c=5; var z=(x*x)-(x); document.write(X-x); document.write(z);
2 Respostas
+ 9
z= 7*7-7
= 42
X-x= 10-7
=3
+ 6
X is set to 10
x is set to 7
c is set to 5. // unused var
z is set to x*x-x ==> 7*7-7 ==> 42
prints X-x ==> 10-7 ==> 3
prints z ==> 42