In the head, you'll need to paste the following code:
<script type="text/javascript" language="JavaScript">
MyImages=new Array();
MyImages[0]='034.jpg';
MyImages[1]='038.jpg';
MyImages[2]='acid2.jpg';
MyImages[3]='boat.jpg';
function newImage()
{
document.getElementById("mainImage").setAttribute("src", MyImages[Math.round(Math.random()*3)])
}
</script>
You'll obviously need to change the file names to what ever files you want to load.
In the <body> tag, you'll also need to add onload="newImage()", so you get something like <body onload="newImage()">
Finally, you need to make sure that you have an image with an ID of "mainImage" on your page somewhere. If you don't, you'll get JavaScript errors.
<img id="mainImage" />