For all you people saying it was 2m/s^2 or 2.5m/s^2, let me clear a few things up for you:
the question asked you to find the acceleration IMMEDIATELY before the crash. between 0-2 seconds the graph was curved, showing increasing acelleration, and then between 2-4 seconds there was a straight line. the impact was at 4 seconds, so you had to find the gradient of the line right before that, and 2-4 seconds was a STRAIGHT line, you could use that. The change in velocity between 2-4 seconds was 8 (was 2m/s at 2seconds and 10m/s at 8). Now, you know how to work out acceleration, its change in velocity/time.
(10-2)/(4-2)= 4m/s^2