I have two arrays arr1 is 2015,03,12
and arr2 is 2015,03,12
how to compare i tryied like this
first method
if(arr1==arr2)
{ alert("same");} else { alert("not same");}
i got not same. please help me anybody.
second method
var dd1 = arr1[2];
var mm1 = arr1[1];
var yy1 = arr1[0];
var dd2 = arr2[2];
var mm2 = arr2[1];
var yy2 = arr2[0];
if(dd2==dd1 && mm2==mmm1 && yy2==yy1){alert("same");}
both methods not working .
any body help me