JavaScript para ... en Strings

const string = 'code';

// using for...in loop
for (let i in string) {
    console.log(string[i]);
}
SAMER SAEID