How do I calculate all exponentiations from x_min ^ y_min to x_max ^ y_max without repeating the results. For example:
- x2 ^ x8 = z
- ...
- x85 ^ y23 = p
- ...
- but x85 ^ y28 = z !
As you can see, the result of z is repeated for different calculations, how can we skip all the following calculations , provided that it is not permissible to compare with previously calculated results ?
# code python 3 min_x, max_x = 5, 127 min_y, max_y = 2, 250 result = '' for x in range(min_x, max_x): for y in range(min_y, max_y): result += str(x ** y)