We exploit the following recursive definition of the power between two non-negative integers:
Implementation (we assume that the method product() is defined in the same class):
public static int power(int b, int e) { if (e == 0) return 1; else return (product(b, power(b, e-1))); }