Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change

Re: can regex contains function?

by soonix (Canon)
on Jun 19, 2020 at 07:29 UTC ( #11118254=note: print w/replies, xml ) Need Help??

in reply to can regex contains function?

Yes you can, see perlretut and perlrequick.

However, for the special case of upcasing the first letter, there is the ucfirst function. Similiar matter has also been discussed here in the monastery: Capitalize the 1st letter of each word, see also in perlfaq 4: How do I capitalize all the words on one line?

Replies are listed 'Best First'.
Re^2: can regex contains function?
by toothedsword (Sexton) on Jun 19, 2020 at 07:44 UTC
    Thank you so much! Now I know how to solve this specific question. But do you know can I instert a function to the regex?

      If I understand your question, the first responder answered it: use the /e qualifier.

        Oh, sorry, I am so careless, Thank you so much!

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://11118254]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (7)
As of 2020-10-27 21:10 GMT
Find Nodes?
    Voting Booth?
    My favourite web site is:

    Results (258 votes). Check out past polls.