I am new to Perl programming.
I need to find and delete partially matching strings in an array.
For example in my array there are strings:
@array = qw(abcd.txt abcdeff.txt abcdweff.txt abcdefrgt.txt);
I just want the first abcd.txt to be saved to the array and to delete the rest (which are similar in the first 4 characters) i.e. so that it will print only abcd.txt when @print "@array";
is called.