Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. What's "lexographically"?

What's "lexographically"?

Scheduled Pinned Locked Moved Unsolved General and Desktop
14 Posts 8 Posters 899 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Q Offline
    Q Offline
    qazaq408
    wrote on 3 Nov 2023, 03:45 last edited by JKSH 11 Mar 2023, 05:18
    #1

    i read Assistant about QJsonObject,there is a function

    QStringList keys()const;
    

    The Assistant tell me "The list is sorted lexographically",what mean about "lexographically",when i search it ,bing just tell me "lexo" is a singer。。。。

    C 1 Reply Last reply 3 Nov 2023, 03:57
    0
    • Q qazaq408
      3 Nov 2023, 03:45

      i read Assistant about QJsonObject,there is a function

      QStringList keys()const;
      

      The Assistant tell me "The list is sorted lexographically",what mean about "lexographically",when i search it ,bing just tell me "lexo" is a singer。。。。

      C Offline
      C Offline
      ChrisW67
      wrote on 3 Nov 2023, 03:57 last edited by ChrisW67 11 Mar 2023, 03:59
      #2

      @qazaq408 Lexicographically (note the spelling) in general means dictionary order (for some language).

      Q 1 Reply Last reply 3 Nov 2023, 06:11
      1
      • C ChrisW67
        3 Nov 2023, 03:57

        @qazaq408 Lexicographically (note the spelling) in general means dictionary order (for some language).

        Q Offline
        Q Offline
        qazaq408
        wrote on 3 Nov 2023, 06:11 last edited by
        #3

        @ChrisW67 said in What's "lexographically"?:

        @qazaq408 Lexicographically (note the spelling) in general means dictionary order (for some language).

        thank you....
        c32df93b-9bdf-4809-a455-f375f2e59b93-image.png

        J 1 Reply Last reply 3 Nov 2023, 08:20
        0
        • C Offline
          C Offline
          CPPUIX
          wrote on 3 Nov 2023, 06:48 last edited by
          #4

          Hi,

          Perhaps this Stack Overflow post could provide useful details:

          • What is lexicographical order?
          1 Reply Last reply
          0
          • Q qazaq408
            3 Nov 2023, 06:11

            @ChrisW67 said in What's "lexographically"?:

            @qazaq408 Lexicographically (note the spelling) in general means dictionary order (for some language).

            thank you....
            c32df93b-9bdf-4809-a455-f375f2e59b93-image.png

            J Offline
            J Offline
            JonB
            wrote on 3 Nov 2023, 08:20 last edited by
            #5

            @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").

            K 1 Reply Last reply 3 Nov 2023, 10:14
            0
            • J JonB
              3 Nov 2023, 08:20

              @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").

              K Offline
              K Offline
              kkoehne
              Moderators
              wrote on 3 Nov 2023, 10:14 last edited by
              #6

              @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

              Director R&D, The Qt Company

              J 1 Reply Last reply 3 Nov 2023, 11:07
              4
              • K kkoehne
                3 Nov 2023, 10:14

                @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

                J Offline
                J Offline
                JonB
                wrote on 3 Nov 2023, 11:07 last edited by
                #7

                @kkoehne Fine, I didn't really think it was worthy of fixing :)

                S 1 Reply Last reply 3 Nov 2023, 20:32
                0
                • J JonB
                  3 Nov 2023, 11:07

                  @kkoehne Fine, I didn't really think it was worthy of fixing :)

                  S Offline
                  S Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on 3 Nov 2023, 20:32 last edited by
                  #8

                  @JonB documentation fixes are always worth ! :-)

                  Interested in AI ? www.idiap.ch
                  Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                  1 Reply Last reply
                  1
                  • C Offline
                    C Offline
                    Chris Kawa
                    Lifetime Qt Champion
                    wrote on 3 Nov 2023, 22:12 last edited by
                    #9

                    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 :)

                    E 1 Reply Last reply 6 Nov 2023, 07:01
                    4
                    • J Offline
                      J Offline
                      JonB
                      wrote on 4 Nov 2023, 08:07 last edited by JonB 11 Apr 2023, 08:08
                      #10

                      I am with @Chris-Kawa. I would simply have replaced with lexicographically. If I had bothered :)

                      1 Reply Last reply
                      0
                      • C Chris Kawa
                        3 Nov 2023, 22:12

                        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 :)

                        E Offline
                        E Offline
                        enjoysmath
                        wrote on 6 Nov 2023, 07:01 last edited by
                        #11

                        @Chris-Kawa The alphabet is simply enlarged to a greater set than a-zA-Z. They are in fact equivalent under this generalization.

                        https://github.com/enjoysmath
                        https://math.stackexchange.com/users/26327/exercisingmathematician

                        C 1 Reply Last reply 6 Nov 2023, 07:56
                        0
                        • E enjoysmath
                          6 Nov 2023, 07:01

                          @Chris-Kawa The alphabet is simply enlarged to a greater set than a-zA-Z. They are in fact equivalent under this generalization.

                          C Offline
                          C Offline
                          Chris Kawa
                          Lifetime Qt Champion
                          wrote on 6 Nov 2023, 07:56 last edited by Chris Kawa 11 Jun 2023, 08:01
                          #12

                          @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.

                          E 1 Reply Last reply 6 Nov 2023, 08:01
                          0
                          • C Chris Kawa
                            6 Nov 2023, 07:56

                            @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.

                            E Offline
                            E Offline
                            enjoysmath
                            wrote on 6 Nov 2023, 08:01 last edited by
                            #13

                            @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 [...]."

                            https://github.com/enjoysmath
                            https://math.stackexchange.com/users/26327/exercisingmathematician

                            C 1 Reply Last reply 6 Nov 2023, 08:05
                            0
                            • E enjoysmath
                              6 Nov 2023, 08:01

                              @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 [...]."

                              C Offline
                              C Offline
                              Chris Kawa
                              Lifetime Qt Champion
                              wrote on 6 Nov 2023, 08:05 last edited by Chris Kawa 11 Jun 2023, 08:06
                              #14

                              @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.

                              1 Reply Last reply
                              3

                              1/14

                              3 Nov 2023, 03:45

                              • Login

                              • Login or register to search.
                              1 out of 14
                              • First post
                                1/14
                                Last post
                              0
                              • Categories
                              • Recent
                              • Tags
                              • Popular
                              • Users
                              • Groups
                              • Search
                              • Get Qt Extensions
                              • Unsolved