Make your own free website on Tripod.com
Hello

Welcome to my page!

Javascript

 
Links

Loaded Dice

 

<script>
//Loaded Dice
//Julio Maravilla October 4, 2007

alert("You will be playing with a loaded dice that does 1 halve the time and and a random number the rest of the times");
var roll;
var roll2;
roll=Math.floor(Math.random()*2)+1;
if(roll==1)
{
alert("You rolled a 1!");
}

else

{
roll2=Math.floor(Math.random()*5)+2;
alert("You rolled a " + roll2 +" !!");
}
</script>

 

 

Links

Contact me

Favorite links

Computer Science

Five Classmates