WLJS LogoWLJS Notebook

GraphTriangleCount

GraphTriangleCount[g] gives the number of triangles in the graph g.

Examples

GraphTriangleCount[CompleteGraph[5]]
GraphTriangleCount[RandomGraph[{20, 50}]]

Please visit the official Wolfram Language Reference for more details.

On this page