How do I clear an array?

How do I clear an entire array?


TestArray = [“1”, “2”, “3”, “4”];

Now when I call a different area I want
TestArray = [“a”, “b”];

But I don’t want the “3” and “4” to remain.
In some instances the areas are large.
I don’t want to have to use …"", “”,""]



or reinitialise it:

testArray = []; // or new Array();

or set its length to 0:

testArray.length = 0;