About 636,000 results
Open links in new tab
  1. string - What is lexicographical order? - Stack Overflow

    Aug 30, 2017 · Alphabetical order is a specific kind of lexicographical ordering. The term lexicographical often refers to the mathematical rules or sorting. These include, for example, proving logically that …

  2. What is string lexicographically? Java - Stack Overflow

    Sep 16, 2015 · The compareTo() method in Java compares two strings "lexicographically". Can someone please simply explain how the lexicographic comparison works in java? I found this post …

  3. What does lexicographically mean? - Stack Overflow

    Apr 30, 2021 · I saw a program in codeforces where it says, "Now Petya wants to compare those two strings lexicographically." I didn't understand it. What does lexicographically mean?

  4. python - Why does this greedy algorithm work for "Lexicographically ...

    Mar 26, 2025 · 2 Lexicographically Smaller: A string a is lexicographically smaller than a string b if in the first position where a and b differ, string a has a letter that appears earlier in the alphabet than the …

  5. What is exact meaning of lexicographically sorted order?

    Nov 1, 2023 · Yes, that is correct. With words lexicographic order is what we naturally expect. It's not so for numbers. Lexicographic sorting does not order them the way most people expect, with your …

  6. String Comparison in Java - Stack Overflow

    Oct 31, 2010 · If you check which string would come first in a lexicon, you've done a lexicographical comparison of the strings! Some links: Wikipedia - String (computer science) Lexicographical …

  7. How can I sort numbers lexicographically? - Stack Overflow

    Jul 2, 2014 · But seriously, this also means: if you can sort an array of strings lexicographically, as Python's sort intrinsically can, then just make the "key string" out of each number and sort that …

  8. How to get the smallest in lexicographical order?

    Dec 30, 2015 · The smallest lexicographical order is an order relation where string s is smaller than t, given the first character of s (s1) is smaller than the first character of t (t1), or in case they are …

  9. Algorithm to find next greater permutation of a given string

    Oct 26, 2009 · Strings can be lexicographically ordered, e.g. "acb" would come before "cab" but after "abc" in a dictionary. My example list is lexicographically ordered. The next greater permutation is the …

  10. sort array lexicographically in javascript - Stack Overflow

    Dec 8, 2018 · The lines in the V8 code implement the sort per ECMA-262 using < and >, which sorts on code unit, not lexicographically (because ASCII code units aren't in lexicographic order).