Multiple Choice
Which of the following correctly converts the algorithm below to JavaScript? (Assume that constants for an empty string (ES) and the line break tag (BR) have been declared.)
Display "Enter your full name: "
Input fullName
Display "Enter your age in years: "
Input age
Display "Hi, " + fullName
Display "You are " + age + " years old."
A) fullName = prompt("Enter your full name:",ES) ;
Age = prompt("Enter your age in years:",ES) ;
B) fullName = prompt("Enter your full name:",ES) ;
Age = prompt("Enter your age in years:",ES) ;
Document("Hi, " + fullName + BR) ;
Document("You are " + age + "years old." + BR) ;
C) fullName = prompt("Enter your full name:",ES) ;
Age = prompt("Enter your age in years:",ES) ;
Document.write("Hi, " + fullName + BR) ;
D) fullName = prompt("Enter your full name:",ES) ;
Age = prompt("Enter your age in years:",ES) ;
Document.write("Hi, " + fullName + BR) ;
Document.write("You are " + age + "years old." + BR) ;
Correct Answer:

Verified
Correct Answer:
Verified
Q2: In the algorithm below, adding 10 years
Q3: An advantage of structured programming is that
Q4: A _ structure evaluates a logical condition
Q5: On a flowchart, _ are used for
Q6: Comments are included in programs to aid
Q8: On a flowchart, _ mark the beginning
Q9: On a flowchart, symbols are connected by
Q10: Methods that assign values to class variables
Q11: On a flowchart, _ are used for
Q12: "Mutator" methods are also called "set" methods.