matching a stuck-record^nopainnogain

a stuck-record is something like “i love fish i love fish i love fish “.

Q: How do u match a stuck record?
A: /(i love fish )\1+/ seems to be the standard solution in literature

On the other hand, “no pain no gain” are not stuck-records but a …. excel column list — AB-AC-AD-…?

Q: Will \d{3} match 287 ?
A: Yes. see p 177 [[ programming perl ]]. Looks like \d behaves like a wildcard just like the dot

Q: will (\d\d){2} match 7193 ?
a: yes

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s