AlphabeticSort

AlphabeticSort[list]

sorts the elements of list into alphabetical order.

AlphabeticSort[list,lang]

sorts using an ordering suitable for the language lang.

Details and Options

Examples

open allclose all

Basic Examples  (2)

Sort words using the default $Language:

Use ordering rules for a specific language:

Scope  (1)

Specify the language as an argument:

Specify the language as an option:

Options  (5)

CaseOrdering  (2)

CaseOrdering->"LowerFirst" is the default value for most languages:

CaseOrdering->"UpperFirst" is the default value for some languages:

IgnoreCase  (1)

IgnoreCase->True treats the uppercase and lowercase forms of a letter as equivalent:

IgnoreDiacritics  (1)

IgnoreDiacritics->True ignores diacritic marks in the specified language:

The same words in a different language may have a different order when ignoring diacritics:

IgnorePunctuation  (1)

IgnorePunctuation->True sorts after removing all punctuation marks and whitespace:

The default value of IgnorePunctuation is False:

Properties & Relations  (1)

AlphabeticSort is equivalent to using Sort plus AlphabeticOrder as an ordering function:

Possible Issues  (2)

In the "Turkish" language, the equivalence between lower and upper case for the letter "i" is different than in other languages:

The IgnoreCase option overrides any value CaseOrdering may have:

Neat Examples  (1)

Use AlphabeticSort to get a sorted list of 2000 random words:

Build a tree with the sorted words:

Wolfram Research (2015), AlphabeticSort, Wolfram Language function, https://reference.wolfram.com/language/ref/AlphabeticSort.html.

Text

Wolfram Research (2015), AlphabeticSort, Wolfram Language function, https://reference.wolfram.com/language/ref/AlphabeticSort.html.

BibTeX

@misc{reference.wolfram_2020_alphabeticsort, author="Wolfram Research", title="{AlphabeticSort}", year="2015", howpublished="\url{https://reference.wolfram.com/language/ref/AlphabeticSort.html}", note=[Accessed: 16-April-2021 ]}

BibLaTeX

@online{reference.wolfram_2020_alphabeticsort, organization={Wolfram Research}, title={AlphabeticSort}, year={2015}, url={https://reference.wolfram.com/language/ref/AlphabeticSort.html}, note=[Accessed: 16-April-2021 ]}

CMS

Wolfram Language. 2015. "AlphabeticSort." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/AlphabeticSort.html.

APA

Wolfram Language. (2015). AlphabeticSort. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/AlphabeticSort.html