Question: What is wrong with the following segment of JavaScript (besides the missing html, body and script tags - I can not type those as they
What is wrong with the following segment of JavaScript (besides the missing html, body and script tags - I can not type those as they interfere with the Blackboard html code)? The way the code appears below, the loop will never be executed and the line of code with the prompt statement in it never appears for the user to respond to.
var BR = "
"; // html line break tag var ES = ""; // empty string
var reply; while ( reply == "Y" ) { document.write("Hello" + BR); reply = prompt("Do you want to print hello again?",ES); }
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
