How to type in Mathematica

I have the following problem
Let dy/dx =|x|
Let y=g(x) the particular solution that verifies g(-1)=7/2, that calls integrate g(x) dx from -2 to 2, the problem is I have no idea how to enter in the program, Can somebody help me?

Dear Luis,

I am not sure whether this is what you need.

sols = DSolve[{y'[x] == Piecewise[{{-x, x < 0}, {x, x >= 0}}], y[-1] == 7/2}, y[x], x]

Note, that the use of Piecewise, which works better than Abs here. You can then plot

Plot[y[x] /. sols, {x, -10, 10}]

Then you can integrate

Integrate[y[x] /. sols, {x, -2, 2}]

Cheers,
M.

Many thanks Marco, today I learned more of Mathematica, I can solve in paper, but I do not know in Mathematica,. Thanks to you I learned