I'm doing a course in complex analysis - and in a question I come to a term that is $[\exp(2\pi i)]^f $ where $f$ is some fraction. I naively proceed with $[\exp(2\pi i)]^f=1^f=1$ which leads to an incorrect answer, where instead I should keep $[\exp(2\pi i)]^f = \exp(2 f \pi i)\ne 1$. This has confused me somewhat (and possibly embarrassingly) - is it incorrect to evaluate the exponential first?
For example, is it $[\exp(2\pi i)]^\frac{1}{4}=\exp(\frac{\pi}{2} i) = i$ or, is it $[\exp(2\pi i)]^\frac{1}{4}=1^\frac{1}{4} = 1$?
Raising complex numbers to a power is problematic because there is an undeterminacy. Notice that
$$e^{i2\pi}=e^{i2k\pi}$$ for every integer $k$ so that
$$(e^{i2\pi})^f$$ could take infinitely many values
$$e^{i2k\pi f}.$$
When $f$ is irrational, the expression has no meaning and remains undefined.
When $f$ is rational, you can choose to consider all $q$ distinct values of
$$e^{i2k\pi p/q},$$ assuming the fraction irreducible.
You can also choose a particular "branch", by constraining the argument to certain range, such as $[0,2\pi)$. In this case
$$(e^{i2\pi})^f=(e^{i\,0})^f=e^{i\,0f}=1.$$