Regular expression: zero or more occurrences of optional character /

What is the regular expression pattern to say:

zero or more occurrences of the character /

?

2

1 Answer

/* 

If your delimiters are slash-based, escape it:

\/* 

* means "0 or more of the previous repeatable pattern", which can be a single character, a character class or a group.

2

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like