in reply to Removing File Extensions

Assuming all filenames in the list have extensions, and that it isn't necessary to preserve the order of items:
my %h = map /(.*)\.(.*)/, @files; @onlyNames = keys %h; @onlyExt = @h{@onlyNames};