Reverse()
Reverses the order of items, such as the characters in a string, the digits in a number, or the elements in an array.
Reverse( string=string );
Returns: String
| Argument | Description |
|---|---|
|
string
string,
required
|
edit
A string or a variable that contains one |
Examples
edit writeDump(
label: "Reverse a string",
var: reverse("abcd")
);
writeDump(
label: "Reverse empty value",
var: reverse("")
);
See also
- Strings
- string.reverse()
- Search Issue Tracker open_in_new
- Search Lucee Test Cases open_in_new (good for further, detailed examples)