In order to find the value of y, we first have to note that the unlabeled angle in the larger triangle, y and the 78 degree angle create a straight line. The unlabeled angle is equal to 36 since it and the other two angles equal 180. So we take that 36, 78 and y and can set that equal to 180.
36 + 78 + y = 180
114 + y = 180
y = 66
Now that we have that value, we can use y and the 90 degree angle to find x.