Is this an ok clone function?
<p>Is this an okay clone function for cloning an object recursively? </p>

<pre><code>function clone(o)
{
    function CloneObject(inObj) 
    {
        for (i in inObj) 
        {
            if(typeof inObj[i] == 'object')
                this[i] = clone(inObj[i]);
            else
                this[i] = inObj[i];
        }
    }

    return new CloneObject(o);
}
</code></pre>

<p>Also, i found out this doesn't work with arrays. How can I clone an array?</p>
