you can use the glob function to make a list of files ending with "a.jpg":
my @list_of_files_to_be_copied = glob ("*a.jpg");
and then process the list of files thus generated.
This is an example of a Perl one-liner with which I copied the files ending with "a.pl" of my current directory (I don't have jpg files here) to a "new_dir" directory:
$ perl -e 'link $_, "./new_dir/$_" for glob ("*a.pl")'
$ ls new_dir
I tested this and the first part worked perfectly as it stored all the correct named images. But the "copy to new_directory" part didn't work and didn't return any errors when I ran it. I used the same syntax you did, so I'm not sure what went wrong.