at 38:52 I used [01][0-9][-./][0-3][0-9][-./]\d{4} here inside [ ] square brackets we don't need to escape the dot (.) it is just dot, if we had used dot outside of square brackets then we had to escape dot. Cuz dot outside [] means everything except newline
Hi, I hope you don't mind if I comment on names for symbols: # is called 'pound' because on British keyboards it is the money symbol £ (try option#) ! is the exclamation point or mark that you referred to later < I call the less-than symbol or angle bracket in HTML > is the greater than symbol (it is bigger on the left side) * is an Asterisk which means star. Commonly called just 'star'. | is sometimes called a pipe or vertical bar THANKS FOR A GREAT VIDEO ! WATCHED FROM BEGINNING TO END and made a note of the PDF cheat sheet. Very useful.
The legendary movie from Feb 1996 was Happy Gilmore! It surely contributed to the recent Kennedy Center honors for Adam Sandler. And a great video released on April 13, 2023 is the RegEx tutorial from Keith Galli, great job.
My body is regex. 🔎📃 10:50 Linguistically speaking, [y] can be a vowel, especially in words like "crypt". Pedantry of course, since it could just be added into the regex if needed. 🤓 36:40 Might not really be up to regex to do data validation. There are better tools for that. 🧰 In fact, integrating these into data workflows would be a good follow-up video for the future. ▶
Really amazing video! Thanks for the great content! For the part where it was allowing you to not escape the period in the square brackets, it's not sublime, you don't need to escape characters inside square brackets, although it won't complain if you do escape them. The only exception I can currently think of is the ^ symbol and only if you put it at the beginning.
You can use the following regular expression in Python to check for a valid two-digit month (01 to 12): import re # Regular expression pattern for two-digit month (01 to 12) pattern = r"^(0[1-9]|1[0-2])$" This is the answer for your question at 39th minute
a period in a character class only matches a period, same for the other metacharacters like ? * +, the reason for this is there is no use to have a character match every character inside a character class, since for that you would not even need a character class, similar reasoning for the other metacharacters
Hi Keith, excellent video on regex.... One of the best videos made ever on youtube on regex.....im glad i found your video.......Can you make video on finding specific word in a sentence ex (i want to cancel my service. Please cancel my hbo, i want to can sail please console my service, im interested in cancelling) multiple words like this and we want to match word only (cancel | can sail |console service) and ommit any other word like 'cancel hbo' 'cancel bill' ..... Any way can i reach out to you personally with sample. Thanks
49:02 You could definitely get everything if you add an extra parenthesis around the thing you want to get in this case (([a-z][A-Z])+[a-z]?)@(\w+\.\w+)
Hey, Thank you for the amazing content. Please Would you mind covering about End to End Pytorch series from the Problem statement, Data Collection, Modeling, Deployment, and Testing
@@KeithGalli Good video Keith, and some good links too. Regex is a fun diversion from time to time, just like playing around with AWK and SED in shell scripts. If you ever get some time to explore hacking binary/executable files I would recommend it, you'll find it very satisfying and right up your street.
37:54 you can use range eg. [1-31]
Oh man, I waited this so long, thank you for this video!
at 38:52 I used [01][0-9][-./][0-3][0-9][-./]\d{4}
here inside [ ] square brackets we don't need to escape the dot (.) it is just dot, if we had used dot outside of square brackets then we had to escape dot. Cuz dot outside [] means everything except newline
Hi, I hope you don't mind if I comment on names for symbols:
# is called 'pound' because on British keyboards it is the money symbol £ (try option#)
! is the exclamation point or mark that you referred to later
< I call the less-than symbol or angle bracket in HTML
> is the greater than symbol (it is bigger on the left side)
* is an Asterisk which means star. Commonly called just 'star'.
| is sometimes called a pipe or vertical bar
THANKS FOR A GREAT VIDEO ! WATCHED FROM BEGINNING TO END
and made a note of the PDF cheat sheet. Very useful.
Finally I understood regex!!! Thank you
You're very welcome! Glad it was helpful.
nothing better than entire you tube . your work is awesome . its really helpful man . thanks a lots
Always super helpful! Thank you Keith :)
Thank you for the video!
In negative lookbehind, try to use \b before the pattern you want to match. It has worked for me!
Thanks for the tip! Glad you enjoyed the video
The legendary movie from Feb 1996 was Happy Gilmore! It surely contributed to the recent Kennedy Center honors for Adam Sandler. And a great video released on April 13, 2023 is the RegEx tutorial from Keith Galli, great job.
Correct, and haha thank you for the kind words! Glad you enjoyed :)
You are the best! Thank you for this video
props from brazil
My body is regex. 🔎📃
10:50 Linguistically speaking, [y] can be a vowel, especially in words like "crypt". Pedantry of course, since it could just be added into the regex if needed. 🤓
36:40 Might not really be up to regex to do data validation. There are better tools for that. 🧰
In fact, integrating these into data workflows would be a good follow-up video for the future. ▶
Ali sent me. Am so glad she did. You have some great videos.
Yes!!!!!!! Favorite tutor about to tackle a subject I've beeeeeeeen wanting to learn! Can't fight fate!
Let's go!!!!!!!!
Really amazing video! Thanks for the great content!
For the part where it was allowing you to not escape the period in the square brackets, it's not sublime, you don't need to escape characters inside square brackets, although it won't complain if you do escape them. The only exception I can currently think of is the ^ symbol and only if you put it at the beginning.
The brackets are also known as "chevrons". Caret is just "^"
I would love to see a video on syntax trees and X' theory!
Omg. Thanks to you, I could understand the regex. You're truly life saver
Glad the video was helpful!!
@@KeithGalliRubén godoy islas
Rubén godoy islas
You can use the following regular expression in Python to check for a valid two-digit month (01 to 12):
import re
# Regular expression pattern for two-digit month (01 to 12)
pattern = r"^(0[1-9]|1[0-2])$"
This is the answer for your question at 39th minute
a period in a character class only matches a period, same for the other metacharacters like ? * +, the reason for this is there is no use to have a character match every character inside a character class, since for that you would not even need a character class, similar reasoning for the other metacharacters
not optimal but (0[1-9]|1[0-2]) would only match months 01-12
That's a smart solution! Didn't think of that, thanks for sharing :)
Great video, Could you please prepare new video(tutorials) about ML?
Very useful!
Hi Keith, excellent video on regex.... One of the best videos made ever on youtube on regex.....im glad i found your video.......Can you make video on finding specific word in a sentence ex (i want to cancel my service. Please cancel my hbo, i want to can sail please console my service, im interested in cancelling) multiple words like this and we want to match word only (cancel | can sail |console service) and ommit any other word like 'cancel hbo' 'cancel bill' ..... Any way can i reach out to you personally with sample. Thanks
49:02 You could definitely get everything if you add an extra parenthesis around the thing you want to get in this case (([a-z][A-Z])+[a-z]?)@(\w+\.\w+)
Hey, Thank you for the amazing content. Please Would you mind covering about End to End Pytorch series from the Problem statement, Data Collection, Modeling, Deployment, and Testing
i gave up on ya after the groups. lol moving on another tutorial
Hey keith, im looking for data science job. Can you help in that, any reference
Так-то ничё! Просто и понятно.
Happy Gilmore 😀
Haha you got it! 🤝
@@KeithGalli Good video Keith, and some good links too. Regex is a fun diversion from time to time, just like playing around with AWK and SED in shell scripts. If you ever get some time to explore hacking binary/executable files I would recommend it, you'll find it very satisfying and right up your street.
the password regex is not working for me!
Hey Keith! Here from Ali's channel. I wanna see my name in sparkles aa
lets go