So this is about (preventing) an off-by-one error in the (interpretation of) English language. I have found some similar (not duplicate) questions but I don't feel entirely comfortable yet. For context, I'm an application developer, and I want my application to be crystal clear. To that end, I've found existing answers to be unsatisfactory.

Let me give an example sentence that should explain it all.

The contract lasts from 1 January to 31 January.

The word to is ambiguous, although in this case is easily understood to be up to and including the 31st. However, it will not always be this easy! In Dutch, we have a simple solution to this ambiguity:

  • het contract duurt van 1 januari tot 1 februari (<)
  • het contract duurt van 1 januari t/m 31 januari (<=)

I want to be able to use both forms in my application, but, again, it needs to be crystal clear to the user which of the 2 is meant.

The English equivalent for t/m that first comes to mind is up to and including. However, that is just too long for my tastes compared to t/m. In Dutch, because it's so short, the ambiguity of tot is almost non-existent because laziness is not an excuse to write tot instead of t/m. I fear that some developers will write up to or until where they actually meant up to and including.

I also considered the word through, so it would be this:

  • The contract lasts from 1 January to 1 February. (<)
  • The contract lasts from 1 January through 31 January. (<=)

Is through really understood by everyone to be up to and including? Or is there an alternative, better word? Or perhaps I'm looking in the wrong direction for a solution and there's a word for to that explicitly excludes the boundary?

So again, to summarize, I'm looking for:

  • a word or phrase that unambiguously means less than
  • a word or phrase that unambiguously means less than or equals
  • @MichaelHarvey Thanks, but I'm not quite sure what your suggestion is. Use until before? I found this question and the answers too vague, and that's exactly what I want to avoid.
    – aross
    Feb 18 at 7:56
  • Does this answer your question? Translation for Dutch "tot en met": until and including?
    – Stuart F
    Feb 19 at 11:05
  • @StuartF Thanks. That question has some nice remarks. But it has to be said that the accepted answer is most definitely not an answer to my question. There's a comment on the question, and the second answer have led me to a complete answer though.
    – aross
    Feb 19 at 14:17
  • Funny that even though I've replied to being marked duplicate, my question was still closed. I feel that my question is broader than simply a translation of t/m. And one of the 2 "duplicates" is nothing like my question.
    – aross
    Feb 19 at 14:33

Thanks to StuartF for pointing me to this question. Though the accepted answer is useless i.r.t this question, there are some remarks that proved quite valuable. Thanks to Fattie for that. I've settled on the following:

  • The contract lasts from 1 January to 1 February exclusive. (<)
  • The contract lasts from 1 January to 31 January inclusive. (<=)

These are both explicit, and, though longer still than tot and t/m, are by far not as long as up to and including.

  • Be careful about inadvertently excluding the start date, not just the end.
    – Lawrence
    Sep 28 at 17:04
  • @Lawrence Is that even an issue in English?
    – aross
    Sep 29 at 16:12
  • Yes, exclusive can mean “excluding both ends”.
    – Lawrence
    Sep 29 at 17:33
  • @Lawrence tbh I see no reason why someone would interpret it that way. The parsing is from 1 January (to 1 February exclusive)
    – aross
    Sep 30 at 8:26

Not the answer you're looking for? Browse other questions tagged or ask your own question.