Javascript clears a variable after there is no further reference it
- by Praveen Prasad
It is said, javascript clears a variable from memory after its being referenced last.
just for the sake of this question i created a JS file with only one variable;
//file start
//variable defined
var a=["Hello"]
//refenence to that variable
alert(a[0]);
//
//file end
no further reference to that variable, so i expect javascript to clear…