Black-box group algorithm for root computation problem based on power computation problem and order-finding problem

Idea and outline
Suppose the order of the group is known to be $$N$$. Use the extended Euclidean algorithm to find a positive integer $$d < N$$ such that:

$$md \equiv 1 \pmod N$$

Now, to find $$h$$ such that $$h^m = g$$ simply compute $$h$$ as $$g^d$$.

Note that in fact, the algorithm does not require knowledge of the exact order of the group. It only requires knowledge of a multiple of the order that is still relatively prime to $$m$$. Moreover, we don't actually need the order of the whole group, we can do with the order of any subgroup of the group containing the element whose root we need to find.