Tin mới
JavaScript: Scripting language
Web APIs: Programming interfaces
Structuring content with HTML module
Dynamic scripting with JavaScript module
String.prototype.codePointAt()
The charAt() method of String values returns a new string consisting of the single UTF-16 code unit at the given index.
The charAt() method of String values returns a new string consisting of the single UTF-16 code unit at the given index.
Zero-based index of the character to be returned. Converted to an integer — undefined is converted to 0.
UTF-16 characters, Unicode code points, and grapheme clusters
Characters in a string are indexed from left to right. The index of the first character is 0, and the index of the last character in a string called str is str.length - 1.
String.prototype.lastIndexOf()
This page was last modified on Jul 10, 2025 by MDN contributors.