do you have to initialize variables in javascript code example
Example 1: how to instialise var in js
var variable-name = number;
/*eg*/
var a = 10;
Example 2: do variables need to be initialized in js?
Yes. Always declare or initialize your variable before using it in
Javascript.