we know that the equation of the altitude to hk passes through point g and is perpendicular to segment hk
step 1 find the slope segment hk h (1.-3) k(2,7) slope m=(y2-y1)/(x2-x1)----> m=(7+3)/(2-1)----> m=10
if two lines are perpendicular so m1*m2=-1
the altitude to hk has a slope m2=-1/10
step 2 with m=-1/10 and point g(-3,4) find the equation of the line y-y1=m*(x-x1)-----> y-4=(-1/10)*(x+3)---> multiply by 10 10y-40=-x-3----> 10y+x=37-----> equation of the altitude