develooper Front page | perl.perl6.users | Postings from October 2022

Re: regex: how to I pick out items in the middle?

Thread Previous
From:
ToddAndMargo via perl6-users
Date:
October 30, 2022 08:33
Subject:
Re: regex: how to I pick out items in the middle?
Message ID:
43f2db02-b791-f6e2-ab92-9665b3c827a7@zoho.com
On 10/30/22 01:24, Elizabeth Mattijsen wrote:
> 
>> Which brings me back to the other of my criticisms
>> of the documentation.  The examples are high level
>> users showing off their skills making for a totally
>> useless example for beginners.  They should show a
>> simple example and then work up to the show off stuff.
> 
> On that note, OOC, what do you think about the level of the "Don't fear the grepper!" blog series:
> 
>      https://dev.to/lizmat/dont-fear-the-grepper-1-1k3e
>      https://dev.to/lizmat/dont-fear-the-grepper-2-4ki5
>      https://dev.to/lizmat/dont-fear-the-grepper-3-hfp
>      https://dev.to/lizmat/dont-fear-the-grepper-4-nki


I have never picked up the grep function.  I
use grep a lot in bash programming, but not
yet in Raku.  I always find something I
like better and also easier to understand
and maintain.  `contains`, `starts-with`,
`ends-with` all comes to mind.  I can even get
fancy and look for the boolean return from
regex, but I have abandoned that approach
as it is harder for me to figure out when
trying to maintain something I have not seen
in a while.  (I find if I do a contains
first, I can instantly figure out what I was
up to.)

Someday maybe I will pick up grep.

I should probably create a note for
grep with these links in it.




Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About