count the number of possible triangles

Solutions on MaxInterview for count the number of possible triangles by the best coders in the world