$string = s/\b(\w+)\b/ucfirst($1)/eg;