<script type = "text/javascript">
<!--
function CountME()
{
document.write("<html><head><title>Script Result</title>");
document.write("<link rel = 'stylesheet' type = 'text/css' href = 'style.css' /></head><body>");
var limitMe =parseInt(prompt('Enter a Number to count down from.','20'),10)
for(i = limitMe; i >= 0; i--) //Create a for loop to count from 1 to 10
{
if(i%10==0)document.write("<br>")// line break just for fun
if (i%2==1) // use the modulus method to get odd numbers (divide i by 2 where there is a remainder of 1)
{
document.write(i+" ") //(write the odd number)
}
}
document.write("</body></html>");
}
// -->
</script>
<input type="button" onclick="CountME()" value ="Run Function">