From my research, the following image is used for the problem. For each segment, the displacement can be obtained by looking for the area under the segment.
Part A:
displacement = (1/2)*10*2 = 10m
Part B:
displacement = [(1/2)*4*5] + (5*2) = 20m
Part C:
displacement = [(1/2)*4*10] + (2*10) = 40m