Answer to Question 09A-2

int power(int x, int n)
{
  int p = 1;
  for(int i = 1; i <= n; i++)
  {
    p *= x;
  }
  return p;
}