String Operations

The Wolfram Language incorporates the latest highly efficient algorithms to allow operations on strings with millions of elements, all making use of the Wolfram Language's unique symbolic string patterns.

StringJoin join strings together

StringSplit split strings at whitespace, or any specified pattern

StringLength length of a string (in Unicode characters)

StringPart  ▪  StringTake  ▪  StringDrop  ▪  StringTakeDrop  ▪  StringInsert

StringTrim trim whitespace etc. from strings

StringRiffle assemble a string from a list, inserting delimiters

StringExtract extract numbered parts defined by delimiters

StringReverse reverse the characters in a string

StringRotateLeft  ▪  StringRotateRight

StringPadLeft  ▪  StringPadRight

StringPartition partition a string into blocks

InsertLinebreaks break a string onto multiple lines

StringPosition find positions of substrings or string patterns

StringCases give all cases of string patterns in a string

StringCount count occurrences of a string pattern

StringContainsQ  ▪  StringFreeQ  ▪  StringMatchQ

StringStartsQ  ▪  StringEndsQ  ▪  PalindromeQ

StringReplace make replacements for substrings or string patterns

StringReplacePart replace substrings at specified positions

StringReplaceList do all possible replacements on a string

Character-Oriented Operations »

ToUpperCase  ▪  ToLowerCase  ▪  Capitalize  ▪  CharacterCounts  ▪  ...

Characters break a string into a list of characters

Sort  ▪  AlphabeticSort  ▪  AlphabeticOrder

Hash compute hash codes for a string

ImportString, ExportString translate between many string formats

StringToStream set up a string to be read sequentially

Read  ▪  Find  ▪  Skip  ▪  SetStreamPosition  ▪  ...

String Data Operations »

SequenceAlignment  ▪  Nearest  ▪  FindClusters  ▪  DictionaryLookup  ▪  ...