What is the number of triangles that can be formed whose vertices are the…
202320252025
What is the number of triangles that can be formed whose vertices are the vertices of an octagon, such that the triangle has only one side common with the octagon?
- A.
64
- B.
32
- C.
24
- D.
16
Show answer & explanation
Correct answer: B
For a convex polygon, any triangle formed using its own vertices can share 0, 1, or 2 sides with the polygon (sharing all 3 sides is impossible unless the polygon itself is a triangle). To count triangles sharing exactly one side, fix one side of the polygon and find how many of the remaining vertices can be the third vertex without accidentally creating a second shared side, then multiply by the number of sides — each such triangle is tied to exactly one side, so there is no double counting.

When such triangles are drawn on the octagon, keeping exactly one side common with it, they look as illustrated below:

Label the octagon's vertices A, B, C, D, E, F, G, H in order, so its sides are AB, BC, CD, DE, EF, FG, GH, and HA.
Consider the side AB first: a triangle keeping AB as its only common side with the octagon needs a third vertex that is not adjacent to A or to B — otherwise a second side (such as HA or BC) would also coincide with the octagon.
Among the remaining vertices, the two adjacent to A and B (namely H and C) are excluded, leaving D, E, F, and G — so the triangles ABD, ABE, ABF, and ABG are the 4 valid triangles for side AB, as illustrated below:

The same reasoning applies to every other side by the octagon's symmetry — for example, side BC similarly gives the 4 triangles BCE, BCF, BCG, and BCH.
Since the octagon has 8 sides and each contributes 4 such triangles, with no triangle counted under more than one side, the total is 8 × 4 = 32.
Cross-check: the total ways to choose any 3 of the 8 vertices is C(8, 3) = 56. Of these, 8 triangles are formed by 3 consecutive vertices and share two sides with the octagon (one such triangle centred on each side), and 32 share exactly one side as found above; the remaining 56 − 8 − 32 = 16 share no side with the octagon at all. These three counts add up to the full 56, confirming the total above.
Hence, the number of triangles with exactly one side common with the octagon is 32.