цикл через строковый типа
const str = "Hello Grepper!";
const chars = [...str];
chars.forEach((c, i) => console.log(c, i));
elcharitas
const str = "Hello Grepper!";
const chars = [...str];
chars.forEach((c, i) => console.log(c, i));