I know i'm most probably nitpicking but... i have the following code:
var book;
var i=0;
i = 300;
book = new CBook();
book.Title = "blahblah";
book.Contents = "lalalala";
function CBook() {
this.Title = "";
this.Contents = "";
}
now my question is:
would it be better to have
var book = {};
instead of
var book;
in the first version typeof(book) returns undefined before the assignment book = new CBook();
thanks in advance