11/11, infinite loop help


#1



https://www.codecademy.com/courses/javascript-beginner-en-ASGIv/2/4?curriculum_id=506324b3a7dffd00020bf661


Not sure why my code is an infinite loop, help would be appreciated.


for (var i = 1; i < 7; i++) {
console.log(i);
};
var trevor = true;
while(trevor) {
    console.log("Trevor loop is working");
    trevor = false;
}
var bob = false;
   do {
       console.log("Bob loop is working");
   }
   while(bob = true);


11. Review help
#2

you do while loop is a infinity loop, you assign a value of true to bob (bob = true) instead of comparing bob with true:

bob == true

#3

ahh , thank you didn't even cross my mind that, that might be the issue.