M/D/YY /^(\d{1,2})\/(\d{1,2})\/(\d{2})$/
M-D-YY /^(\d{1,2})\-(\d{1,2})\-(\d{2})$/
M.D.YY /^(\d{1,2})\.(\d{1,2})\.(\d{2})$/
M/D/YY /^(\d{1,2})\/(\d{1,2})\/(\d{2})$/ M-D-YY /^(\d{1,2})\-(\d{1,2})\-(\d{2})$/ M.D.YY /^(\d{1,2})\.(\d{1,2})\.(\d{2})$/
Share
Watch out, now there is a new capturing group, so the year will be in backreference number 4 instead of 3 as before.
If you also want to allow
M/D-YYetc., then you can use