Pizza Cutting Type: Math Diff: 2.0
Tricks
The result is: 1+ triangular number. i.e. if Ivan cut the pizza with �n� straight cut then he can maximum cut it pieces. So simple a calculation.
But remember the input range is very high. So the result do not fit in unsigned int. I use long long as data type for this problem.
Related Problems & Topics
If you have any advice, complements
or proposal, please Send mail to Author
Submit