/* Return a random number between 0 and num */
function rand(num)
	{
		return (Math.floor(Math.random() *num));
	}

/* The following array holds the actual file names of the images that can be chosen randomly */
Images = new Array(8);
Images[0] = "band/gibsonband5.jpg";
Images[1] = "band/prizeband.jpg";
Images[2] = "cw/cw1.jpg";
Images[3] = "cw/cw3.jpg";
Images[4] = "quilts/quilt3.jpg";
Images[5] = "quilts/quilt5.jpg";
Images[6] = "flag2.jpg";
Images[7] = "flag3.jpg";


/* Set this variable so that as the array shrinks or grows, we won't need to change the call to the random function. This will make it easier to maintain the list of images. */
NumberOfImages = Images.length;

/* Center the image */
document.write("<CENTER>");
document.write("<TABLE WIDTH=100% CELLSPACING=0 CELLPADDING=0 BORDER=0>");

/* Choose a random image from the list and display it and its caption on the web page */
ChosenImage = rand(NumberOfImages);

document.write("<TR><TD>");
document.write("<IMG SRC=",Images[ChosenImage],">");
document.write("</TD></TR>");


/* Stop centering */
document.write("</TABLE>");
document.write("</CENTER>");
