how to sync between two functions
<p>I have two functions that I want to call to third function when the other functions( one and two ) will be finished.
I need that the first function and the second function will be called Asynchronous.
for example</p>

<pre><code>  var func1 = function( do something..... return arr )
  var func2 = function ( do something ..... return arr2 )

   if ( arr.length &gt; 0  &amp;&amp; arr2.length &gt; 0 )
       var func3 = function( do something )
</code></pre>

<p>my qeustions:</p>

<ol>
<li><p>what is the best way to do it ?</p></li>
<li><p>How I call to function in Asynchronous way ? </p></li>
</ol>
