50% off: Unlimited data and AI learning.
State of Data and AI Literacy Report 2025

OpenRepGrid (version 0.1.9)

strReverse: reverse a string

Description

reverses the strings of a vector, i.e. c("ABC", "abc") becomes c("CBA", "cba")

Usage

strReverse(x)

Arguments

x
a string or a vector of strings

Value

vector a string or vector of strings with reversed chars

References

http://www.mail-archive.com/r-help@r-project.org/msg102759.html

Examples

Run this code
strReverse(c("ABC", "abc"))

Run the code above in your browser using DataLab