Unexpected end of script? 10/11


#1

I was wondering what I had gotten wrong in this code. It states that I had ended my code unexpectedly. I was wondering if I am supposed to end the function with a "getToDaChoppa();".

var getToDaChoppa = function(){
// Write your do/while loop here!
var no = true
do {
console.log("Hi" + no);
var no = false
}
while (no===true);
getToDaChoppa();


#2

@icknam,

You are forgetting a closing-curly-bracket-}
with which you close the getToDaChoppa FUNCTION-BODY

var getToDaChoppa = function(){
 // Write your do/while loop here!
    var no = true;
    do {
        console.log("Hi" + no);
        //VARIABLE =no= is allready defined !!
        no = false;
    } while (no===true);
  };
getToDaChoppa();