The first thing you need to do is setup the integral. You have a triangle with given vertices so you will need a double integral.
The definition of mass (in this case) is Integral (over A) d(x,y) dA where A is the region of the triangle. (Usually density is with respect to volume).
Hint: Since d(x,y) is a function of x, I'd suggest you formulate the region A in terms of two triangles which have an edge parallel to the y-axis. (It will help you a lot if you draw a diagram on paper and separate the triangles in the way I've mentioned).