Number of all possible triangles
= Number of selections of 3 points from 8 vertices
$=^8C_3=56$
Number of triangle with one side common with octagon $= 8 ? 4 = 32$
(Consider side $A_1A_2$. Since two points $A_3, A_8$ are adjacent, 3rd point should be chosen from remaining 4 points.)
Number of triangles having two sides common with octagon : All such triangles have three consecutive vertices, viz., $A_1A_2A_3, A_2A_3A_4, ..... A_8A_1A_2.$
Number of such triangles $= 8$
$\therefore$ Number of triangles with no side common $= 56 - 32 - 8 = 16.$