adplus-dvertising
frame-decoration

Question

Which one of the following regular expression matches any string containing zero or one p?

a.

p+

b.

p*

c.

P?

d.

p#

Posted under PHP

Answer: (c).P?

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. Which one of the following regular expression matches any string containing zero or one p?