Make your own free website on

~Chao Li~

~Kumo no Mukou, Yakusoku no Basho~


<title>Joke Teller</title>
//Joke Teller
//Chao Li. October 10, 2007.
//demonstrates the while loop

var correct = "to get to the other side";
var guess = "";

while (guess != correct)
guess = prompt ("Why did the chicken cross the road?", "");

if (guess == correct)
alert ("Pretty funny, huh?");

alert ("that's not it...");
}// end if
}//end while


<h1>Joke Teller<br></h1>