hello monks,
I have a array, which values are duplicated once in the same array. I need to remove the second occurence value. I have tried as below, but not getting result. Pls help me to solve this
Thanks
Siva
@content = split(/ /, $content); @Original = @content; for ($i=0; $i<=$#content; $i++) { for ($j=0; $j<$i; $j++) { print "$j\n"; if ($content[$i] == $content[$j]) { $Original[$i] = ""; } } } print "@processing";
In reply to remove duplicate value in array by sivaramanm
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |