I tried to compare the 2 arrays. I should be able to get thatarray1 array2 the_for_below and_press this_job online_Please #note that we have space at b +egining of online_Please. complete the_form_below #note that we have space at t +he end of the_form_below. and_press submit_will_only #note that we have space at b +egining of and_press.
I tried with my code:array1[0]=array2[2] i.e. the_for_below = complete array1[3]=array2[0] i.e. the_for_below = and_press
But it does not show the desired output instead displays all the elements of array2 with each of the element of array1. Like...for ($k=0;$k<$i;$k++) #where $i is the length of array. { for($l=0;$l<$i;$l++){ if(chomp($array1[$k]) eq chomp($array2[l])) { print"\n$array1[$k],$array2[$l]"; } }
Please guide me through this... Thanking youthe_for_below and_press the_for_below online_Please the_for_below the_form_below the_for_below submit_will_only this_job and_press this_job online_Please this_job the_form_below this_job submit_will_only ... and so on..
In reply to compare 2 arrays of strings by sharan
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |