An implementation of regex golf in perl