var theImages = new Array()
theImages[0] = 'images/photo01.jpg'
theImages[1] = 'images/photo02.jpg'
theImages[2] = 'images/photo03.jpg'
theImages[3] = 'images/photo04.jpg'
theImages[4] = 'images/photo05.jpg'
theImages[5] = 'images/photo06.jpg'
theImages[6] = 'images/photo07.jpg'
theImages[7] = 'images/photo08.jpg'
theImages[8] = 'images/photo09.jpg'
theImages[9] = 'images/photo10.jpg'
theImages[10] = 'images/photo11.jpg'
theImages[11] = 'images/photo12.jpg'
theImages[12] = 'images/photo13.jpg'
theImages[13] = 'images/photo14.jpg'
theImages[14] = 'images/photo15.jpg'
theImages[15] = 'images/photo15.jpg'
theImages[16] = 'images/photo15.jpg'
theImages[17] = 'images/photo15.jpg'
var j = 0
var p = theImages.length;
var preBuffer = new Array()
for (i = 0; i < p; i++){
   preBuffer[i] = new Image()
   preBuffer[i].src = theImages[i]
}
var whichImage = Math.round(Math.random()*(p-1));
function showImage(){
document.write('<img src="'+theImages[whichImage]+'">');
}