<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<TITLE>Practice Exercises</TITLE>
<SCRIPT LANGUAGE="JavaScript">
<!-- Hide script from older browsers
// Below defines the answers. Only correct buttons have correct answers.
Answer = new Array("",
"","","","","5", //Answers for 1 thru 5 buttons
"","","","4","", //Answers for 6 thru 10 buttons
"","","","","5"); //Answers for 11 thru 15 buttons
// Below defines the computescore function.
function computescore () // Name the function to be defined
{ // Start the function definition
var nCorrect=0; // Set the variables to their starting values
var nItems = 3;
var nButtons = 15;
var score = 0;
for (i=1; i<=nButtons; i++) // For the 1st to the 15th radio button repeat
{ // the following series of commands
if ( (document.PE1.elements[i].value == Answer[i]) && // If button correct
(document.PE1.elements[i].checked == true) ) // & checked
nCorrect+=1; // Add 1 to nCorrect
}
score = (Math.floor((nCorrect/nItems)*10000+0.5))/100; //Compute % & Round
return score; //Return score when
//function executes
} // End the function definition
// -->
</SCRIPT>
</HEAD>
<BODY>
<HR>
<FORM NAME="PE1" onReset="return confirm('Clear entries? Are you sure?')">
<STRONG>
<H1><CENTER>Logical Element Practice Exercises</CENTER></H1>
<PRE>NAME: <INPUT TYPE="text" NAME="ID" SIZE=25></PRE>
<H3>
Enter the single best answer to each question below.
</H3>
<HR>
<P>
<B>Item 1:</B><BR>
What HTML logical element typically produces underlined text?<BR><BR>
<INPUT NAME="Q1" TYPE="RADIO" VALUE=1 CHECKED onClick="alert('Sorry, try again.');">No Response<BR>
<INPUT NAME="Q1" TYPE="RADIO" VALUE=2 onClick="alert('STRONG typically does not produce underlining. Please try again.');">STRONG <BR>
<INPUT NAME="Q1" TYPE="RADIO" VALUE=3 onClick="alert('Sorry, CITE is for citations.');">CITE<BR>
<INPUT NAME="Q1" TYPE="RADIO" VALUE=4 onClick="alert('U is not correct. It is a physical element.');">U<BR>
<INPUT NAME="Q1" TYPE="RADIO" VALUE=5 onClick="alert('None is correct, congratulations.');">None of the above<BR>
<BR>
<B>Item 2:</B><BR>
What HTML logical element typically produces italic text?<BR><BR>
<INPUT NAME="Q2" TYPE="RADIO" VALUE=1 CHECKED onClick="alert('Sorry, try again.');">No Response<BR>
<INPUT NAME="Q2" TYPE="RADIO" VALUE=2 onClick="alert('There is no ITALIC element, Sorry, try again.');">ITALIC <BR>
<INPUT NAME="Q2" TYPE="RADIO" VALUE=3 onClick="alert('Your response is incorrect. Please try again.');">I<BR>
<INPUT NAME="Q2" TYPE="RADIO" VALUE=4 onClick="alert('EM is correct. Congratulations.');">EM<BR>
<INPUT NAME="Q2" TYPE="RADIO" VALUE=5 onClick="alert('H1 produces the largest heading size. Try again.');">H1<BR>
<BR>
<B>Item 3:</B><BR>
What HTML logical element typically produces superscript text?<BR><BR>
<INPUT NAME="Q3" TYPE="RADIO" VALUE=1 CHECKED onClick="alert('Sorry, try again.');">No Response<BR>
<INPUT NAME="Q3" TYPE="RADIO" VALUE=2 onClick="alert('SUP is a physical element. Please try again.');">SUP<BR>
<INPUT NAME="Q3" TYPE="RADIO" VALUE=3 onClick="alert('SUB is a physical element. Please try again.');">SUB<BR>
<INPUT NAME="Q3" TYPE="RADIO" VALUE=4 onClick="alert('S is a physical element. Try again.');">S<BR>
<INPUT NAME="Q3" TYPE="RADIO" VALUE=5 onClick="alert('None of the above is correct.');">None of the above<BR>
<BR>
<HR>
<CENTER>
<INPUT TYPE="RESET" VALUE="Clear Entries"><BR><BR>
<INPUT TYPE="BUTTON" VALUE="Show Score" onClick="alert('Your score is '+computescore()+'%.');">
</CENTER>
</STRONG>
</FORM>
</BODY>
</HTML>