in reply to Split using multiple conditions

You can use a single expression like bart showed, but I find the following easier to understand (and maintain):

# Seperate the fields. my @feeder_line = split /\s+/; # Clean up the data: # Remove the brackets from the 2nd and 3rd fields. foreach (@feeder_line[1, 2]) { s/^\[//; s/\]$//; }