/***********************************************
* JavaScriptKit.com Multiple Choice Quiz Script (http://www.javascriptkit.com)
* Copyright 2003 JavaScript Kit- http://www.javascriptkit.com
* This notice and footnote must stay intact for use
* Visit JavaScript Kit (http://www.javascriptkit.com/) for full source code
***********************************************/

//Enter total number of questions:
var totalquestions=63

//Enter the solutions corresponding to each question:
var correctchoices=new Array()
correctchoices[1]='d' // April 27, 1777'
correctchoices[2]='a' // George Washington'
correctchoices[3]='c' // eight'
correctchoices[4]='a' // one'
correctchoices[5]='b' // In 1799, during an outbreak of Yellow Fever.'
correctchoices[6]='d' // Sybil ran a tavern.'
correctchoices[7]='a' // George Washington'
correctchoices[8]='d' // David Wooster'
correctchoices[9]='c' // 4'
correctchoices[10]='b' // 300 guineas'
correctchoices[11]='c' // In Branford, CT in 1739'
correctchoices[12]='a' // The French and Indian War'
correctchoices[13]='a' // May 1, 1760'
correctchoices[14]='b' // A fertile farming area that was surrounded by dense wilderness.'
correctchoices[15]='c' // A primitive oil well.'
correctchoices[16]='d' // August 3, 1825 at the age of 80'
correctchoices[17]='a' // Women and girls'
correctchoices[18]='d' // Member of Congress'
correctchoices[19]='d' // 20'
correctchoices[20]='b' // Compo Beach'
correctchoices[21]='a' // Captain Stephen Rowe Bradley'
correctchoices[22]='c' // About three years later.'
correctchoices[23]='c' // Isaac Keeler'
correctchoices[24]='b' // Alexander Hamilton'
correctchoices[25]='d' // More than 400.'
correctchoices[26]='d' // The entire day and most of the night.'
correctchoices[27]='c' // Between 2:00 and 3:00 in the afternoon.'
correctchoices[28]='a' // Sunny.'
correctchoices[29]='d' // Patriot houses were spared.'
correctchoices[30]='b' // About 2,000 men.'
correctchoices[31]='b' // The Patriots were out-numbered 3 to 1.'
correctchoices[32]='d' // Sanford Barlow.'
correctchoices[33]='d' // Colonel Ludington's Regiment'
correctchoices[34]='b' // Colonel.'
correctchoices[35]='a' // Benedict Arnold'
correctchoices[36]='c' // The U.S. Congress'
correctchoices[37]='c' // The Spy by James Fenimore Cooper'
correctchoices[38]='b' // For Col. Ludington.'
correctchoices[39]='c' // 17'
correctchoices[40]='a' // A notorious Tory highwayman.'
correctchoices[41]='a' // Sybil ran a tavern.'
correctchoices[42]='b' // In Branford, CT in 1739.'
correctchoices[43]='b' // Patriot houses were spared.'
correctchoices[44]='b' // Isaac Keeler'
correctchoices[45]='c' // David Wooster'
correctchoices[46]='a' // 14'
correctchoices[47]='d' // August 3, 1825 at the age of 80'
correctchoices[48]='d' // A primitive oil well.'
correctchoices[49]='F' // False'
correctchoices[50]='F' // False'
correctchoices[51]='F' // False'
correctchoices[52]='T' // True'
correctchoices[53]='T' // True'
correctchoices[54]='T' // True'
correctchoices[55]='T' // True'
correctchoices[56]='F' // False'
correctchoices[57]='F' // False'
correctchoices[58]='F' // False'
correctchoices[59]='T' // True'
correctchoices[60]='F' // False'
correctchoices[61]='F' // False'
correctchoices[62]='F' // False'
correctchoices[63]='F' // False'

/////Don't edit beyond here//////////////////////////

function gradeit(){
var incorrect=null
for (q=1;q<=totalquestions;q++){
	var thequestion=eval("document.myquiz.question"+q)
	for (c=0;c<thequestion.length;c++){
		if (thequestion[c].checked==true)
		actualchoices[q]=thequestion[c].value
		}
		
	if (actualchoices[q]!=correctchoices[q]){ //process an incorrect choice
		if (incorrect==null)
		incorrect=q
		else
		incorrect+="/"+q
		}
	}

if (incorrect==null)
incorrect="a/b"
document.cookie='q='+incorrect
if (document.cookie=='')
alert("Your browser does not accept cookies. Please adjust your browser settings.")
else
window.location="results.htm"
}


function showsolution(){
var win2=window.open("","win2","width=200,height=350, scrollbars")
win2.focus()
win2.document.open()
win2.document.write('<title>Solution</title>')
win2.document.write('<body bgcolor="#FFFFFF">')
win2.document.write('<center><h3>Solution to Quiz</h3></center>')
win2.document.write('<center><font face="Arial">')
for (i=1;i<=totalquestions;i++){
for (temp=0;temp<incorrect.length;temp++){
if (i==incorrect[temp])
wrong=1
}
if (wrong==1){
win2.document.write("Question "+i+"="+correctchoices[i].fontcolor("red")+"<br>")
wrong=0
}
else
win2.document.write("Question "+i+"="+correctchoices[i]+"<br>")
}
win2.document.write('</center></font>')
win2.document.write("<h5>Note: The solutions in red are questions that you incorrectly answered.</h5><p align='center'><small><a href='http://www.javascriptkit.com' target='_new'>JavaScript Kit quiz script</a></small>")
win2.document.close()
}

