In case this is a homework, here is a hint on a similar example.
Let $ A = \{ x \in \mathbb{R} | x^2-x-6 > 0 \}.$ First, factor $ x^2-x-6 = (x-3)(x+2) = 0$. Hence there are two roots at $x =3, x= -2$. This divides up the number line $\mathbb{R}$ into three intervals: $ (-\infty, -2), (-2, 3), (3, \infty). $ Now you need to check the sign of $(x-3)(x+2)$ in each of the three intervals. Only $x \in (3, \infty) \cup (-\infty, -2)$ makes $(x-3)(x+2)$ positive, i.e. $x^2-x-6 > 0.$ Hence $ A = (3, \infty) \cup (-\infty, -2). $ Do the same with $A,B$ in your question. Then $A \cup B$ should be apparent. Note: pay attention that $B$ has $\le$ in the definition, so some intervals will be closed (rather than open).