+ 1
Confused about lesson question
I am confused as to why \AS...\b.\Z should match 'SPAM!' in search. I understand the \A looks for the beginning and the S is there so that's a match, and what the \b does it ok, but since there is a '.' and not '!' at the end, then how come \Z is matching '.' and '!' ?? Totally lost.
2 Answers
+ 3
. is used to match anything (character/space).
And
! Is used to say the last letter of string
+ 1
Hi Nassim,
i recommend you this ressource: https://regexr.com/
It helps to work on your regular expressions and also has a cheat sheet, where you can find all the character classes.
Have a nice day!