Consider the following 2 investing strategies.
Strategy $A$ buys $1$ share in every period.
Strategy $B$ invests a fixed amount of money in every period.
$B$ seems better because for the same amount of money it gets more shares.
The task is to generalize the above example using the arithmetric mean - geometric mean inequality for a general $1$-dimensional price process in discrete time ($N$ periods)
Do you understand what exactly I have to do? I don't know where to start or how to apply the AM-GM inequality here

Let the prices be $p_i$ in each period. Then the total cost if you buy $1$ share in each period is $\sum p_i$. OTOH, if you fix a constant amount for spending in each period, for the same total cost you can spend $\frac1n \sum p_i$ in each period. Then using Cauchy-Schwartz inequality we can get: $$\frac1n \sum p_i \cdot \sum \frac1{p_i} \geqslant n$$ Notice that the LHS represents number of shares bought by investing the fixed amount, while the RHS is the number of shares by buying a share in each period. Instead of CS inequality, you could AM-HM, or other approaches.