Find the smallest positive integer $n$, such that for any sequence of $n$ positive integers $a_{1}, a_{2}, \cdots, a_{n}$ satisfying $\sum_{i=1}^{n} a_{i}=2007$, there must be a sum of some consecutive terms equal to 30. (Provided by Tao Pingsheng)
First, we can construct an integer sequence $a_{1}$, $a_{2}, \cdots, a_{1017}$ with 1017 terms, such that there are no consecutive terms whose sum is 30; for this, take $a_{1}=$ $a_{2}=\cdots=a_{29}=1, a_{30}=31$, and $a_{30 m+i}=a_{i}, i \in\{1,2, \cdots, 30\}$, $m \in \mathbf{N}$, i.e., $\left\{a_{k}\right\}$ is: $1,1, \cdots, 1,31,|1,1, \cdots, 1,31,| \cdots \mid 1$,
$1, \cdots, 1, 31, \mid 1,1, \cdots, 1$ (a total of 34 segments, the first 33 segments each have 30 terms, the last segment has 27 terms, totaling 1017 terms). Secondly, when the number of terms is less than 1017, it is only necessary to merge some consecutive numbers in certain segments into larger numbers.

For any sequence of 1018 positive integers $a_{1}, a_{2}, \cdots, a_{1018}$ that satisfies the condition $\sum_{i=1}^{1018} a_{i}=2007$, we will prove that there must be consecutive terms whose sum is 30. For this, let $S_{k}=\sum_{i=1}^{k} a_{i}, k=1,2, \cdots, 1018$, then
$$
1 \leqslant S_{1}<S_{2}<\cdots<S_{1018}=2007 .
$$

Now consider the grouping of elements in the set $\{1,2, \cdots, 2007\}$:
$$
\begin{array}{l}
(1,31),(2,32), \cdots,(30,60) \text {; } \\
(61,91),(62,92), \cdots,(90,120) ; \\
(121,151),(122,152), \cdots,(150,180) \text {; } \\
(60 k+1,60 k+31),(60 k+2,60 k+32), \cdots, \\
(60 k+30,60(k+1)) ; \\
(60 \cdot 32+1,60 \cdot 32+31),(60 \cdot 32+2,60 \cdot 32+32), \cdots \text {, } \\
(60 \cdot 32+30,60 \cdot 33) \text {; } \\
1981,1982, \cdots, 2007 . \\
\end{array}
$$

There are $33 \times 30=990$ pairs and 27 numbers that are not in pairs, from which 1018 numbers are taken as the values of $S_{k}$, there must be two numbers taken from the same pair, let them be $\left(S_{k}\right.$, $\left.S_{k+m}\right)$, then $S_{k+m}-S_{k}=30$, i.e., in the sequence
$$
a_{k+1}+a_{k+2}+\cdots+a_{k+m}=30 .
$$

Therefore, the minimum value of $n$ is 1018.