I need an explaination on this
<p>I have to rewrite a web application and there is some javascript code that I was trying to understand.</p>

<p>There is this simple function</p>

<pre><code>function declareVars(value)
{
    this.value = value;
}
</code></pre>

<p>That is called this way</p>

<pre><code>var frequency_factor = new declareVars(1);
</code></pre>

<p>Then, there are things like</p>

<pre><code>frequency_factor.value = 1;
</code></pre>

<p>And so, I was trying to understand why someone would do that instead of simply doing something like</p>

<pre><code>var frequency_factor = 1;
</code></pre>

<p>Hope anyone can enlighten me on this.
Thanks</p>
