Math
posted by Luisa .
A triangle has vertices X(0,0), Y(4,4), and Z (8,4).
a) Write an equation for each of the three medians
b) Recall that the centroid of a triangle is the point of intersection of the medians of the triangle. Use the equations from part a) to verify that (4,0) is the centroid of triangle XYZ.
I've been trying to solve this problem for over an hour and the equations I'm getting for part a) don't match the answers in tha back of my book, y=0, x4=0, and x+y4=0. I really need some help, please

Let the midpoints of XY,YZ, and XZ be P,Q, and R respectively
Did you get P(2,2), Q(6,0) and R(4,2) ?
XQ is obviously y = 0, the equation of the xaxis
YR has undefined slope, so its equation is x=4
Right there you already have the coordinates of the centroid, namely (4,0)
the slope of PZ is (42)/(82) = 1
so y=x+b, sub in (2,2) for
2=2+b
b=4
so y = x + 4
(notice that (4,0) satisfies this last median equation.
BTW, a quick way to find the centroid if you know the three vertices of a triangle...
centroid = (sum of x values/3,sum of y values/3) 
oh, thank you so much!
it all makes sense now, my book was just so confusing on the topic and I cannot even begin to express hoe grateful I am; I was so desperate and overwhlemed by this.
Thank you!