What's "lexographically"?
-
-
@qazaq408
Just a heads-up: Despite the spelling shown in the Qt documentation, there is no such word as "lexographical", it is indeed "lexicographical", as @ChrisW67 noted :) See e.g. https://www.spellcheck.net/misspelled-words/lexographical.Is just means "alphabetical" (as opposed to e.g. "numerical").
-
@JonB said in What's "lexographically"?:
Is just means "alphabetical" (as opposed to e.g. "numerical").
Indeed, let's just fix this in the documentation itself: https://codereview.qt-project.org/c/qt/qtbase/+/515970
-
It's a bit of a nitpick, yes, but "alphabetical" and "lexicographic" orders are not the same thing. One is a subset of the other, like squares and rectangles. Alphabetical order is based on (surprise) the alphabet, which usually doesn't include digits or other special characters. Lexicographic order is based on any general sequence or dictionary, so it's far better fit for the subject, as QString is not limited to just letters of any particular alphabet.
So in short that documentation change replaces a typo with inaccuracy. Which is better?
There, that's my contribution. Hopefully your eyes didn't roll too much :) -
I am with @Chris-Kawa. I would simply have replaced with
lexicographically
. If I had bothered :) -
@Chris-Kawa The alphabet is simply enlarged to a greater set than a-zA-Z. They are in fact equivalent under this generalization.
-
@enjoysmath No. An alphabet is a specific set of graphemes (scribbles) that represent phonemes (sounds we make when speaking). You can't enlarge it to encompass, say, emojis or new line character, same as you can't enlarge the definition of a square to represent all rectangles. Well, you can, but that's just inventing new stuff unnecessarily and confusing, same as calling cars bicycles, because it's just larger number of wheels. QString does not represent an alphabet. It can hold any number of them and a lot more stuff that is not part of any alphabet.
Under the existing definitions of these words you can't sort a set of arbitrary UTF characters alphabetically. You can sort them lexicographically.
-
@Chris-Kawa Incorrect. An alphabet is simply a set of symbols. Emoji's included if they're encoded say in something usable such as Unicode. But even if they're not, in a math paper I could create an alphabet {❤, 🍕} if I wanted to. In linguistic / formal language terms, this is the definition. Usually you start out "Let $\Sigma$ be a finite alphabet [...]."
-
@enjoysmath That's a set, list, group, vector or a number of other things. It's not an alphabet, because it doesn't represent phonemes (unless you can make a sound of pizza). We're talking about sets of characters, so linguistic definition of an alphabet is better suiting than that of a formal language theory. You learn your ABCs in a language class, not in math class.