📜  for...of...loop - CSS 代码示例

📅  最后修改于: 2022-03-11 14:47:56.635000             🧑  作者: Mango

代码示例1
const array = ['a', 'b', 'c', 'd'];
for (const item of array) {
    console.log(item)
}
// Result: a, b, c, d

const string = 'Ire Aderinokun';
for (const character of string) {
    console.log(character)
}
// Result: I, r, e, , A, d, e, r, i, n, o, k, u, n