In the workshop, we discussed about the maximum number of regions formed using straight lines. But what if we have Bent Lines as shown. Given N bent Lines and an infinite sized plane, we need the maximum number of regions in which the plane can be divided. See the figure for examples.
Each line contains a value of N. Read till EOF.
0<= N <= 3 x 109
Each line contains the maximum number of regions.
Problem Setter: Rounak Tibrewal