Why is this not working?


#1

/*jshint multistr:true */
var text = "Evan,blah blah blah Roanoke blah Evan"
var myName = "Evan"
var hits = []

for (var i = 0; i < text.length;) {
if (text[i] === "E") {
for (var j = i;j < i + myName.length;) {
hits.push(text[j])
}
}
}


#2

makes no sense why i checked forum multiple times to try and fix this