It's such a sucky language!

I've been hacking at it today to try and extract an image name from some html. To do it you can use split() to parse it to a list and then test the list for the correct ending.

That sounds nice and easy - and it is. But it still took me at least an hr to get owrkign properly!

Python it much easier :P

EDIT: and ok yes i know that the piece of code was piss easy to put together and this just highlights how sleepy I am today. But still...

my @nameList = split(/"/, $data); if(@nameList[1] =~ /\.(.*)$/i) {

# blah

}