If the second argument is 10 then the result is the same as the first argument. If P 0 return 1. We dont have to use in-built function Mathpow.
Public class ExampleProgram public static void mainString args int basenumber 2 exponent 3.
Long temp 1. C Program to Calculate the Power of a Number Without Using MathPow. Similarly 5 -2 152 125. Examples of Power function.