Function Powers
<p>I have to write a main( ) routine to test the results of the following test cases:</p>

<p>power(8, 2)</p>

<p>power(3, 3)</p>

<p>power(2, 10)</p>

<p>Use cout to display the computed values on screen.
This is what I have done so far but its not working for me</p>

<pre><code>#include &lt;iostream&gt;
#include &lt;cmath&gt;

using namespace std;

int pwr (int&amp;, int);

int main ()
{
int m, n;
cout &lt;&lt; "Enter two positive integers;";
cin &gt;&gt; m &gt;&gt; n;
cout &lt;&lt; endl &lt;&lt; "The power is " &lt;&lt; pwr(m,n) &lt;&lt; endl;
return 0;
}

int power (int m, int n)
{
if (n&lt;=1)
    return m;
else
    return m * power (m, n-1);
}
</code></pre>
