What is the sum of the x-coordinates of all distinct solutions to the system of equations y=∣2x−1∣ and y=x+2?
−31
1
2
38