Which of the following is satisfied by all numbers $x$ of the form
\[x=\frac{a_1}{3}+\frac{a_2}{3^2}+\cdots+\frac{a_{25}}{3^{25}}\]
where $a_1$ is $0$ or $2$, $a_2$ is $0$ or $2$,...,$a_{25}$ is $0$ or $2$?
$\mathrm{(A)\ } 0\le x<1/3 \qquad \mathrm{(B) \ } 1/3\le x<2/3 \qquad \mathrm{(C) \  } 2/3\le x<1 \qquad$
$\mathrm{(D) \  } 0\le x<1/3 \text{ or }2/3\le x<1 \qquad \mathrm{(E) \  }1/2\le x\le 3/4$
We can separate this into two cases.
Case 1: $a_1=0$ Here, clearly the minimum sum is when all of the $a_i$ are $0$, so $0\le x$. The maximum sum is when the rest of the $a_i$ are all $2$. In this case, \[\sum_{n=2}^{25}\frac{2}{3^n}<2\sum_{n=2}^{\infty}\frac{1}{3^n}=2\left(\frac{\frac{1}{9}}{1-\frac{1}{3}}\right)=\frac{1}{3}.\] Therefore, in this case, $0\le x<1/3$.

Case 2: $a_1=2$ Here, again, the minimum sum is when the rest of the $a_i$ are all $0$, in which case the minimum sum is $\frac{2}{3}$. The maximum sum is attained when all of the $a_i$ are $2$. In that case, \[\sum_{n=1}^{25}\frac{2}{3^n}<2\sum_{n=1}^{\infty}\frac{1}{3^n}=2\left(\frac{\frac{1}{3}}{1-\frac{1}{3}}\right)=1.\] Therefore, in this case, $2/3\le x<1$.
Thus, we must have $0\le x<1/3$ or $2/3\le x<1$, $\boxed{\text{D}}$.