Saturday, January 28, 2012

pow() Method


The pow() method returns the value of X to the power of Y .

JavaScript Code:

<script type="text/javascript" language="javascript">

    function powFun()
    {
        alert(Math.pow(3, 3));
    }

</script>

HTML Code:

<button onclick="this.powFun();" id="powid" value="Click here!" />

No comments: