The File::Basename module does what you need:
use strict; use File::Basename; print basename $_ for <DATA>; __DATA__ /home/users/me/proteins/1hc9.txt /home/users/me/proteins/193l.txt /home/users/me/proteins/1trz.txt /home/users/me/proteins/2psg.txt
In reply to Re: extracting data
by Corion
in thread extracting data
by Angharad
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |