Comparing two arrays using javascript
<pre><code>var array1 = [column1,column2,column3,column4];
var array2 = [column1 [empid],column2 [mobno],column4 [place]];
</code></pre>

<ul>
<li>if array1 has any of array2 values. I mean, in above case column1,column2,column4 is there in array1, then remove those values and array1 should have only column3 and then append array1 value with array2.</li>
<li>after check and remove, now <code>array1 = [column3]</code> then append <code>array1</code> value with <code>array2</code> and finally</li>
<li><code>array2 = [column1 [empid],column2 [mobno],column3,column4 [place]];</code> it should be in correct index position</li>
</ul>

<p>is above case possible?</p>
