Average power of finite length discrete signal
A finite length signal has a power of zero. This becomes obvious if you just use the first formula in your question and apply it to a signal of finite length. Finite length signals are so-called energy signals, and their energy is given by

$$E_x=\sum_{n=0}^{N-1}\big|x[n]\big|^2\tag{1}$$

where $N$ is the length of the signal (and we assume that the signal is defined in the index range $n\in[0,N-1]$).

The expression

$$P_x=\frac{1}{N}\sum_{n=0}^{N-1}\big|x[n]\big|^2\tag{2}$$

is the power of an $N$-periodic signal, as explained in this answer.