* quantifier matches zero or more occurences.
In practice, this means that
will match every possible input, including the empty string. So your regex matches at the start of the input string and returns the empty string.
More Related Contents:
- Is it possible to escape regex metacharacters reliably with sed
- Regex: match everything but a specific pattern
- Regular expression for duplicate words
- Regular Expression for alphanumeric and underscores
- How to match multiple occurrences of a substring
- Find and kill a process in one line using bash and regex
- Regular expression to match standard 10 digit phone number
- Regex: matching up to the first occurrence of a character
- Convert a char to upper case using regular expressions (EditPad Pro)
- Why is a character class faster than alternation?
- Regex: Remove lines containing “help”, etc
- How to check if a line is blank using regex
- What is the complexity of regular expression?
- How to Use/Enable (RegExp object) Regular Expression using VBA (MACRO) in word
- Remove .php from urls with htaccess
- R dplyr: rename variables using string functions
- What does ?= mean in a regular expression?
- Regular Expressions with repeated characters
- What is the Regular Expression For “Not Whitespace and Not a hyphen”
- replace a part of a string with REGEXP in sqlite3
- Why do ^ and $ not work as expected?
- Is there an online RegexBuddy-like regular expression analyzer? [closed]
- Regular Expression Match to test for a valid year
- how to use a regular expression to extract json fields?
- Searching for all variations of hyphens and dashes in Regex
- How do I remove all non-ASCII characters with regex and Notepad++?
- “Unknown escape sequence” error in Go
- shell script. how to extract string using regular expressions
- Capturing text before and after a C-style code block with a Perl regular expression
- Regular expression to match a valid absolute Windows directory containing spaces