In FF 5.0.1, I get this result:
var arr = [1,2,3];
typeof arr.constructor // function
But without the typeof, I get this:
var arr = [1,2,3];
arr.constructor // [ undefined ]
...which does show undefined, but it is in an Array. I'm guessing this is simply a display issue in FireBug.
Try doing this:
var arr = [1,2,3];
var arr_2 = arr.constructor( 4,5,6 );
...you'll see that arr_2 is the Array you'd expect.
With regard to your .join() not being a function, it is because s is still a String, not an Array. This is because .split() does not change the String into an Array, but rather returns an Array.
You could do this,
s = s.split(" ");
var joined = s.join(' ');
... and it will work.
joinis an array function in JavaScript. Btw,v.constructorshowsfunction Array() {[native code]}in the web console.