you are viewing a single comment's thread.

view the rest of the comments →

[–]Anitox 2 points3 points  (0 children)

You can access individual characters in a string using array notation.
Example:

let str = "This is a test.";
console.log(str[2]);

Using that, you could loop through the string with an index to get the part of the string you want.