As the triangle in the question is a right angled triangle we can use Pythagoras Theorem , a2+b2=c2. c is the size of the longest size which is what we are looking for and a and b are lengths 8 and 15.Therefore c2=82+152, c2=64+225, c2=289, c=sqrt(289), c=17. So the length of the longest side is 17