There are so many times the Oxford comma prevents ambiguity. I have yet to see a counterexample. Commas separate list entries, don't change it for the last one.
"I'd like to thank my mother, Ayn Rand, and God" is the usual example.
Yes, you can reorder the list to remove the ambiguity, but sometimes the order of the list matters. The serial comma should be used when necessary to remove ambiguity, and not used when it introduces ambiguity. Rewrite the sentence when necessary. Worth noting that this is the Oxford University Press's own style rule!
Just put the colon there if you need to introduce a list, it's one of its functions. "I'd like to thank: my mother, Ayn Rand and God". The same goes for that "two strippers" example: "We invited the strippers: JFK and Stalin, to the party".
Only tangentially related (but hey, it's HN) - I'm so happy about the support/requirements for trailing commas in the modern language syntax:
x = [
123,
456,
789,
];
It makes editing such a list so much easier. Also, the commit diffs are cleaner (you don't need to add comma to the last element when appending a new one).
There are so many times the Oxford comma prevents ambiguity. I have yet to see a counterexample. Commas separate list entries, don't change it for the last one.
Wikipedia has an interesting example where it's still ambiguous:
It's not clear whether Betty is the maid. But tbh removing the comma doesn't help either.Personally if I wanted to indicate that Betty was the maid I would put "a maid" between brackets or hyphens.
"I'd like to thank my mother, Ayn Rand, and God" is the usual example.
Yes, you can reorder the list to remove the ambiguity, but sometimes the order of the list matters. The serial comma should be used when necessary to remove ambiguity, and not used when it introduces ambiguity. Rewrite the sentence when necessary. Worth noting that this is the Oxford University Press's own style rule!
Just put the colon there if you need to introduce a list, it's one of its functions. "I'd like to thank: my mother, Ayn Rand and God". The same goes for that "two strippers" example: "We invited the strippers: JFK and Stalin, to the party".
I always heard this one...
We invited the strippers, JFK, and Stalin to the party. [three groups invited - strippers, a president, and a premier]
We invited the strippers, JFK and Stalin to the party. [the president and premier are strippers]
Very different visual conjured by those two sentences.
"John helped his uncle, Jack off a horse"
"John helped his uncle Jack off a horse"
Two very different outcomes...
I'd prefer:
We invited the strippers, JFK and Stalin, to the party [two strippers, named JFK and Stalin]
if the goal is to minimize ambiguity.
Only tangentially related (but hey, it's HN) - I'm so happy about the support/requirements for trailing commas in the modern language syntax:
It makes editing such a list so much easier. Also, the commit diffs are cleaner (you don't need to add comma to the last element when appending a new one).My very first programming language doesn't use commas:
Spoilers: There is no "why not" in the article (aside from "tradition").
There is a book "Eats Shoots and Leaves" that gets at the importance of knowing when (and when not) do deploy the punctuation:
https://www.amazon.com/Eats-Shoots-Leaves-Tolerance-Punctuat...?
I also enjoy how meaning of a whole sentence can be inverted by a bit of punctuation:
a. "A woman without her man is nothing."
b. "A woman: without her, man is nothing."
It is important to use the Oxford Comma because it is commonly accepted, fits with tradition, and is just correct.
.. and in your example, unnecessary.
Or maybe I missed the joke.
You mean "Why, and Why Not"
You'd only use the Oxford comma when the list is 3 or more items.
Still funny.
obligatory oxford comma: https://www.youtube.com/watch?v=P_i1xk07o4g