Please help me find x thank you so much :)

Answer:
x= 27
Step-by-step explanation:
a triangle always has 180 degrees, therefore:
(3x-17)+(x+40)+(2x-5)= 180
6x+18=180
6x=162
x=162/6
x=27