Regular expression matching any non white space char string ending with "&s"
Tried RE:
\S*&s
The issue is \S includes all the chars including "&s". In my string when "&s" occurs RE should end over there but it is not.
Example :
String:
abcd$%+abv&sabc
String extracted by RE: abcd$%+abv&s
Asked
Active
Viewed 12 times
0

lil-wolf
- 372
- 2
- 15
-
What is expected output for a string like `123&s678&s`? Two matches, `123&s` and `678&s`, or no match? – Wiktor Stribiżew Mar 30 '20 at 11:58
-
1Looks like you just need `\S*?&s` – Wiktor Stribiżew Mar 30 '20 at 12:01