In school, I was always taught not to use Oxford Commas, but I've recently decided to use them because I'm writing non-fiction and clarity is important to me. However, it's difficult to unlearn 30 years of not using them, so I've tried to come up with a regular expression to find missing Oxford Commas.
This is the best I've come up with so far:
Code:
[a-zA-Z0-9]+, [a-zA-Z0-9]+ and
(there is a space after the
and but it's getting stripped by the forum software).
It's not perfect, but it's the best I've come up with. Can anyone improve on it?