Find Characters with Lazy Matching, Learning about Regular Expressions in 2020, Learn Regex Features

Lesson Summary

In this regular expression tutorial, we continue looking at available regex features. Specifically, we look at regular expression lazy matching. With lazy matching regular expressions, we simply mean, finding the shortest possible part of a string that achieves the pattern of the regular expression. We learn that, by default, regular expressions use greedy matching. This means that the regex returns the longest possible string that satisfies the regular expression pattern. This means if we want to find the shortest possible pattern we must use lazy matching to correctly match the desired pattern. Learning about lazy matching allows one to target the smallest pattern matches for our regex. Learning how the concept works are key, so that you may be aware of it for any future use when needed. Support the Movement, buy a sticker, https://believerationally.com/shop​ Check out Bae's products and crafts https://ValeryeDoesResin.com​ Listen to some of my music, https://Ananomyx.com

Subscribe To Monthly Newsletter. Chance to Win Monthly Prizes

* indicates required