Answer: 78 degrees.
Explanation:
By definition, the sum of the interior angles of a triangle is 180 degrees.
Then, keeping on mind that two angles of a triangle are 40 degrees and 62 degrees, you can calculate the third angle as following, where x is the missing angle:

Therefore, the third angle measures 78°.