right (JavaScript)
Gets a substring starting at the right.
Parameters |
Description |
count |
The number of characters to get. |
Return value |
Description |
string |
The substring. |
Usage
This method gets the number of characters
specified by the parameter starting at the last index and working
backwards.
Examples
The following example returns
Tokyo
.
var cities = new String("Paris Moscow Tokyo");
cities.right(5)
Have feedback?
Google Analytics is used to store comments and ratings. To provide a comment or rating for a topic, click Accept All Cookies or Allow All in Cookie Preferences in the footer of this page.