function Foo() {
alert(this === a);//return false! **why this is not equal a?**
}
var a = new Foo();//create a new object
foo is a constructor,why this in the 'Foo' is not equal with 'a'.
The assignment to the variable a has not yet happened when you're inside the constructor. The sequence of events is:
a.true is because both this.name and a are undefined. That isn't accomplishing anything.i think "this" referring to as a object, but "this.a" is true as that is the object