i am newbie to regex in javascript and i got stuck in using regex in javascript.
I have two scenerio
1) I have a string like aaa/+/bbb/+ , i want to match this string with strings aaa/1/bbb/hello123 and aaa/1/bbb/ using regex and both should return true. If i pass aaa/1/bbb then it should give false
2) If i have string aaa/# then it should match all the above strings and returmn true
Can any one help me?
+and#is? It looks like+is intended to match one or more numbers and letters, but it's not clear.2) If i have string aaa/# then it should match all the above strings and returmn true- no it shouldn't#shouldn't be aloud to have that meaning.aaa/#will not match the strings given. But I think I understand where I went wrong, I assumed he meant thataaa/#was actually a RegExp - re-reading the question, I see he wants someone to write some code for his own pattern matching scheme, possibly using RegExp as required - this is not icanhazcode.com so I wish him the best of luck in his quest to get free programming donei got stuck in using regex- you sure have, @Qasim, you haven't got ANY code at all - good luck