Refactor 'pow(double x, int n)'.