📌  相关文章
📜  获取字符串的第 n 个字符 javascript 代码示例

📅  最后修改于: 2022-03-11 15:01:11.693000             🧑  作者: Mango

代码示例2
const place = "Denmark";

const n = 0; // 0 indexed i.e. 1st character
const firstCharacter = place.charAt(n);

console.log(firstCharacter); // D