Given n points in a plane and no more than two points are collinear, the task is to count the number of triangles in a given plane.
Input : n = 3 Output : 1 Input : n = 4 Output : 4
Let there are n points in a plane and no three or more points are collinear then number of triangles in the given plane is given by
- Number of Triangles that can be formed given a set of lines in Euclidean Plane
- Number of triangles that can be formed with given N points
- Number of triangles formed from a set of points on three lines
- Program to check if three points are collinear
- Count of different straight lines with total n points with m collinear
- Hammered distance between N points in a 2-D plane
- Program to check whether 4 points in a 3-D plane are Coplanar
- Program to find equation of a plane passing through 3 points
- Minimum number of points to be removed to get remaining points on one side of axis
- Prime points (Points that split a number into two primes)
- Number of Integral Points between Two Points
- Maximum number of region in which N non-parallel lines can divide a plane
- Number of triangles that can be formed
- Number of triangles after N moves
- Count the number of possible triangles
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to firstname.lastname@example.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.