Triangle Side Sum


Submit solution

Points: 1
Time limit: 1.0s
Memory limit: 256M

Author:
Problem type

You are given two integer segment lengths A and B, find the sum of all possible integer C such that we can construct a triangle with A, B and C.

Especificación de entrada

The input contains two integers A and B (1 <= A, B <= 10^9).

Especificación de salida

Print the requested sum.

Ejemplo de entrada

2 2

Ejemplo de salida

6

Sugerencia(s)

Use long long data type.


Comments

There are no comments at the moment.