Example 5 Let $M=\{1,2, \cdots, 1995\}, A$ be a subset of $M$ and satisfy the condition: if $x \in A$, then $15 x \notin A$. The maximum number of elements in $A$ is $\qquad$
(1995, National High School Mathematics Competition)
Solution: From the given, we know that at least one of the numbers $k$ and $15k$ does not belong to $A$.

Since $\left[\frac{1995}{15}\right]=133$, when $k=134,135$, $\cdots, 1995$, $15k$ definitely does not belong to $A$.

Similarly, $\left[\frac{133}{15}\right]=8$, when $k=9,10, \cdots, 133$, $k$ and $15k$ cannot both belong to $A$. At this time, at least $133-$ $8=125$ numbers do not belong to $A$. Therefore,
$|A| \leqslant 1995-125=1870$.
Furthermore, we can take $A=\{1,2, \cdots, 8\} \cup\{134,135, \cdots$, $1995\}$, so the maximum value of $|A|$ is 1870.