Hi ! I wouldlike to know a regex formation who match with my exemple, pls
Itās composed of 3 of more elements separate by spaces.
First, the letter a which always needs to be here (compulsory).
After, a b āoptionalā element, which can be b1 or b2, b3⦠When I say optional that means this element can just be not here.
Then, other optionals elements like b: for c it will be c1 or c2, c3⦠BUT the trick is that when you donāt write an element, the match needs to stop just before it. That means if you omit one optional element all the other on his right will donāt match too. So do you understand ? I really hope yes, thank you in advance !
Regex Optional Cases
Aerosmite
#1
0 Likes
Aerosmite
#3
I already try this, maybe it isānt a bad way. Do you think there is an other answer, this way will be not very useful with a lot of optionals elements, no ? And you forget the spaces between ^^
0 Likes