The other way to deal with it is to use split /,/ anyway, and then just know that there is a comma at the end of the string. You could even stick it back on if you wanted to.
But it makes me wonder why you want the comma. I bet you really want foo1, not the quotes, not the comma. Probably if you re-consider whatever processing happens next, your code might simplify.
Or maybe I'm wrong.
TomDLux--
TTTATCGGTCGTTATATAGATGTTTGCA
In reply to Re: another split question
by TomDLux
in thread another split question
by Angharad
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |