2017 Fall Waterloo Local ACM Contest, Problem A
Vera has five sticks of distinct lengths . Vera may choose any three of the five sticks to form the sides of a triangle. How many different triangles can Vera make? Each triangle must have positive area and sticks cannot be bent or cut.
Input
Line contains integers .
Output
Print one line with one integer, the number of ways to form a triangle.
Sample Input 1
1 2 3 4 5
Sample Output 1
3
Sample Input 2
1 2 4 8 16
Sample Output 2
0
Note
For the first example, the ways to form a triangle are choosing sticks or or .
Comments