已知集合 $A=\{x|| x-1 \mid < 2\}, B=\left\{x \mid \log _3 x \leqslant 1\right\}$, 则 $A \cup B=$
$ \text{A.} $ $(-1,3)$
$ \text{B.} $ $(0,3]$
$ \text{C.} $ $(0,3)$
$ \text{D.} $ $(-1,3]$
【答案】 D
【解析】
$\because \mid x-1| < 2 \Rightarrow-2 < x-1 < 2 \Rightarrow-1 < x < 3, \therefore A=(-1,3), \because \log _3 x \leqslant 1=\log _3 3, \therefore 0 < x \leqslant 3$, $\therefore B=(0,3], \therefore A \cup B=(-1,3]$, 故选 D.