Step 1: Understand the modulus:
The function \( |x| \) equals \( x \) when \( x \geq 0 \) and \( -x \) when \( x < 0 \).
So the integral cannot be done in one piece. We split the interval at \( x = 0 \), where the rule changes.
Step 2: Split the integral:
\[ \int_{-2}^{2} |x|\,dx = \int_{-2}^{0} (-x)\,dx + \int_{0}^{2} x\,dx \]
Step 3: Evaluate each part:
First part: \( \int_{-2}^{0} (-x)\,dx = \left[ -\frac{x^2}{2} \right]_{-2}^{0} = 0 - \left( -\frac{4}{2} \right) = 2 \).
Second part: \( \int_{0}^{2} x\,dx = \left[ \frac{x^2}{2} \right]_{0}^{2} = \frac{4}{2} - 0 = 2 \).
\[ \int_{-2}^{2} |x|\,dx = 2 + 2 = 4 \]
Step 4: Why the other options are wrong:
Option (B) 3 and option (D) 0 do not match the sum \( 2 + 2 \). Option (D) comes from forgetting the modulus: \( \int_{-2}^{2} x\,dx = 0 \) because \( x \) is an odd function, but \( |x| \) is never negative, so its integral cannot be 0.
Option (C) 2 is only one of the two equal halves. The area on the left of the y-axis is also 2, so both halves must be added.
Final Answer:
The value of the integral is 4, which is option (A).
\[ \boxed{4} \]