Javascript object constructor vs object literal
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/4597926/creating-objects-new-object-or-object-literal-notation">creating objects - new object or object literal notation?</a><br>
  <a href="http://stackoverflow.com/questions/12356994/literal-notation-vs-constructor-to-create-objects-in-javascript">Literal notation VS. constructor to create objects in JavaScript</a>  </p>
</blockquote>



<p>I'm going through my very first Javascript tutorial.</p>

<p>I just found two ways to create a JS object.</p>

<pre><code>var person = new Object();
person.name = "Tom";
person.age = "17";
</code></pre>

<p>and</p>

<pre><code>var person = {};
person.name = "Tom";
person.name = "17"
</code></pre>

<p>Any difference between these two ways of object creation? Since the second looks simpler, can we always use it under any condition? </p>
