stri_reverse: Reverse Each String

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/reverse.R

Description

Reverses the order of the code points in every string.

Usage

1

Arguments

str

character vector

Details

Note that this operation may result in non-Unicode-normalized strings and may give peculiar outputs for bidirectional strings.

See also stri_rand_shuffle for a random permutation of code points.

Value

Returns a character vector.

Author(s)

Marek Gagolewski and other contributors

See Also

The official online manual of stringi at https://stringi.gagolewski.com/

Examples

1
2
3
stri_reverse(c('123', 'abc d e f'))
stri_reverse('ZXY (\u0105\u0104123$^).')
stri_reverse(stri_trans_nfd('\u0105')) == stri_trans_nfd('\u0105') # A, ogonek -> agonek, A

stringi documentation built on Nov. 29, 2021, 9:12 a.m.