자바스크립트 - for of 반복
See the Pen for of by nilgi (@nilgi) on CodePen. • for (variable of iterable) 반복 가능한 요소 반복 - 문자 반복 const name = "Tistory"; let text = ""; for (const x of name) { text += x; } - 배열 반복 const name2 = ["T", "i", "s", "t", "o", "r", "y"]; let text2 = ""; for (const x2 of name2) { text2 += x2; } - new Set 반복 const name3 = new Set(["T", "i", "s", "t", "o", "r", "y"]); let text3 = ""; for (const x3 of n..
2023. 1. 26.