Help


#1

My code
/*jshint multistr:true */
var text ="I just bought a couple more online classes. So I ll prob work on those \ We all be learning";

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

Oops, try again. Careful: your second 'for' loop should stop when it reaches its current point in the string + myName.length.


#2

the condition in your second for loop should bej < (myName.length + i)

when your if condition is true, i will hold the index of the first letter of your name, this value you assign to j. so between i and i + myName.length will contain your name


#3

Thanks For the willing ness to help


#4

Did you resolve the issue?


#5

Yes I did thank you.