Step 1: Break the integral into intervals based on the greatest integer function.
The greatest integer function \( \left[ x + 1 \right] \) takes integer values between the intervals where \( x \) is between integer values. Break the integral into separate intervals:
- From \( -2 \) to \( -1 \), \( \left[ x + 1 \right] = -1 \)
- From \( -1 \) to \( 0 \), \( \left[ x + 1 \right] = 0 \)
- From \( 0 \) to \( 1 \), \( \left[ x + 1 \right] = 1 \)
Step 2: Calculate the integral.
Now calculate each part of the integral:
\[
\int_{-2}^{-1} (-1) dx = -1, \quad \int_{-1}^{0} (0) dx = 0, \quad \int_{0}^{1} (1) dx = 1
\]
So the total integral is:
\[
-1 + 0 + 1 = 0
\]
Step 3: Conclusion.
The correct answer is (B) 0.