Utf8.reverse

From Multi Theft Auto: Wiki
Revision as of 16:58, 15 February 2016 by Necktrox (talk | contribs) (Created page with "__NOTOC__ {{Shared function}} Reverses the input string. ==Syntax== <syntaxhighlight lang="lua">string utf8.reverse ( string input )</syntaxhighlight> ===Required Arguments=== *'''input:''' A string c...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Reverses the input string.

Syntax

string utf8.reverse ( string input )

Required Arguments

  • input: A string character sequence

Returns

Returns a string containing the reversed original UTF-8 string.

Example

Click to collapse [-]
Client

This example shows how to reverse a UTF-8 string.

local input = "今日は素晴らしい日です"
local output = utf8.reverse( input )
outputConsole( output ) -- すで日いしら晴素は日今

See Also