var vminutes = 5;
var vseconds = 00;
var boxedanswers = 0;
var autocomplete = 1;
var gamever = 0;
var justincase1 = 0;
var justincase2 = 0;


function loadanswers()
{
	answers = new Array();
	answers.push( new inans('3M', new Array()));
	answers.push( new inans('Alcoa', new Array()));
	answers.push( new inans('American Express', new Array()));
	answers.push( new inans('AT&T', new Array('AT and T')));
	answers.push( new inans('Bank of America', new Array()));
	answers.push( new inans('Boeing', new Array()));
	answers.push( new inans('Caterpillar', new Array()));
	answers.push( new inans('Chevron Corporation', new Array('Chevron')));
	answers.push( new inans('Citigroup', new Array()));
	answers.push( new inans('Coca-Cola', new Array('Coca Cola')));
	answers.push( new inans('DuPont', new Array()));
	answers.push( new inans('ExxonMobil', new Array('Exxon Mobil')));
	answers.push( new inans('General Electric', new Array()));
	answers.push( new inans('General Motors', new Array()));
	answers.push( new inans('Hewlett-Packard', new Array('Hewlett Packard')));
	answers.push( new inans('Home Depot', new Array()));
	answers.push( new inans('Intel', new Array()));
	answers.push( new inans('IBM', new Array()));
	answers.push( new inans('Johnson & Johnson', new Array('Johnson and Johnson')));
	answers.push( new inans('JPMorgan Chase', new Array()));
	answers.push( new inans('Kraft Foods', new Array()));
	answers.push( new inans('McDonald\'s', new Array('McDonalds')));
	answers.push( new inans('Merck', new Array()));
	answers.push( new inans('Microsoft', new Array()));
	answers.push( new inans('Pfizer', new Array()));
	answers.push( new inans('Procter & Gamble', new Array('Procter and Gamble')));
	answers.push( new inans('United Technologies Corporation', new Array('United Technologies')));
	answers.push( new inans('Verizon Communications', new Array('Verizon')));
	answers.push( new inans('Walmart', new Array()));
	answers.push( new inans('Walt Disney', new Array()));
	remaining = answers.length;
	displayRemaining();
}

function doEndAlert()
{
	var total = (correct + remaining);
	var percentunrounded = (correct/total) * 100;
	var percent = roundNumber(percentunrounded,2)
	if ( percent == 100 ) {
	alert("Nicely done. You named them all.\nYou got all " + correct + " answers correct.\nWell done!!!");
	}
	if ( percent >= 80 && percent < 100) {
	alert("Well done! You managed to get " + correct + " correct.\nThat is " + percent + "% of the total possible answers.\nThat is an amazing score");
	}
	if ( percent >= 60 && percent < 80) {
	alert("Great Job! You managed to get " + correct + " correct.\nThat is " + percent + "% of the total possible answers.\nThat is a very good score");
	}
	if ( percent >= 45 && percent < 60) {
	alert("Good Job! You managed to get " + correct + " correct.\nThat is " + percent + "% of the total possible answers.\nThat is a good score");
	}
	if ( percent >= 25 && percent < 45) {
	alert("Not bad! You managed to get " + correct + " correct.\nThat is " + percent + "% of the total possible answers.\nThat is a average score");
	}
	if ( percent < 25) {
	alert("Not very good, I'm afraid! You managed to get " + correct + " correct.\nThat is " + percent + "% of the total possible answers.\nThat is a not a very good score");
	}
}
