1

I want to talk about collections where each element may be one of a couple types, either X or Y (independently of others).
If English had parentheses, I could say "contains only (X or Y)s". And that's the logic I used in a computer program.

But in a textual comment explaining the program's goal, I preferred to speak of the whole collection, which is likely to (1) contain a mix of Xs and Ys, though allowed to (2) contain only Xs, or (3) only Ys.

I originally used "contains only Xs and Ys" wording but was questioned by a colleague why I said "and".
Apparently they read it to mean "must contain some Xs and some Ys, and nothing else" — scenario (1) only.
Is "only Xs and Ys" inherently ambiguous between (1)/(2)/(3) vs (1) meanings?

Can I write "contains only Xs or Ys"?
I'm worried that's also inherently ambiguous, could be read as "either only Xs (2) or only Ys (3) but not both"?

How about "contains only Xs and/or Ys"?
Is that a good way to capture (1)/(2)/(3) clearly?

Is there a "distributive law" for how to read conjunctions after "only"?

4
  • The starting position is that only Xs AND Ys is the "natural" way to describe the situation when every item is either X or Y (feasibly they're all Xs or all Ys; the proportional distribution is irrelevant / unspecified). So if you used only Xs OR Ys, many people would assume you meant they're EITHER all Xs or all Ys - simply because if that wasn't what you meant, you'd have probably used AND anyway. But in terms of actual English language, the OR version is inherently ambiguous (there's no scope for ambiguity with the AND version). Commented Sep 4, 2022 at 17:19
  • If it's a requirement that every item be either X OR Y, AND there must be at least one of each type, you'd have to use more words to specify the situation. Commented Sep 4, 2022 at 17:22
  • There is no requirements of at least one of each type. Personally I thought "only Xs and Ys" is clear, as you are saying, but a colleague has read it differently 🤷. Even if I turn out to be "correct", I'm interested in suggestions how to word it for less de-facto ambiguity. Commented Sep 4, 2022 at 20:18
  • 1
    Your colleague's interpretation sounds nonsensical to me. Like I said, only Xs and Ys simply specifies that every item is either an X or a Y - it's agnostic as to whether they're all X or all Y. But assuming your colleagues are effectively your target audience, you'll just have to use as many words as necessary to make sure they don't misunderstand. This isn't about what phrasing is "correct". It's about what your audience will unambiguously understand. Commented Sep 5, 2022 at 3:27

1 Answer 1

1

It is a logical issue. Using "A or B or both" is an effective usage for dealing with this type of logical difficulty.

But preliminary understandings are needed:
Xs is taken to mean {one or more of X}
Ys is taken to mean {one or more of Y}

only {Xs and Ys} = {one or more X and one or more Y}
= there are Xs and Ys
meaning (1)

only {Xs or Ys} = {One or more X} or {one or more Y}
=there are Xs and no Ys, or there are Ys and no Xs
meanings (2) or (3)

only {Xs or Ys or both} = {One or more X but no Y} or {one or more Y but no X} or {both}
= any number (from none upwards) of X and any number (from none upwards) of Y

The use of "or both" captures the meaning that is missing from usages (1), (2) and (3)

1
  • Delighted to see this accepted and helpful. It really is not a matter of opinion, but one of logic affecting usage (as can often happen).
    – Anton
    Commented Sep 8, 2022 at 14:56

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .