360. The sums of the terms of each of the arithmetic progressions, having $n$ terms, are equal to $n^{2}+p n$ and $3 n^{2}-2 n$. Find the condition under which the $n$-th terms of these progressions will be equal.
Given the problem,

$$
S_{1}=\frac{a_{n}+a_{1}}{2} \cdot n=n^{2}+p n, \quad S_{2}=\frac{b_{n}+b_{1}}{2} \cdot n=3 n^{2}-2 n
$$

from which we get

$$
a_{n}+a_{1}=2(n+p), \quad b_{n}+b_{1}=2(3 n-2)
$$

where $a_{i}$ are the terms of the first progression, and $b_{i}$ are the terms of the second progression. For $n=1$, $a_{1}=1+p$, $b_{1}=1$,

$$
a_{n}=2(n+p)-1-p, \quad b_{n}=2(3 n-2)-1
$$

If $a_{n}=b_{n}$, then

$$
2(n+p)-1-p=2(3 n-2)-1
$$

or $p=4(n-1)$ - the required condition.