# Task
A cake is sliced with `n` straight lines. Your task is to calculate the maximum number of pieces the cake can have.

# Example

 For `n = 0`, the output should be `1`.
 
 For `n = 1`, the output should be `2`.
 
 For `n = 2`, the output should be `4`.
 
 For `n = 3`, the output should be `7`.
 
 See the following image to understand it:
 
 ![](https://cdn2.scratch.mit.edu/get_image/project/92275349_500x400.png?v=1450672809.79)

# Input/Output


 - `[input]` integer `n`

  `0 ≤ n ≤ 10000`


 - `[output]` an integer

  The maximum number of pieces the sliced cake can have.

Difficulty: EASY
Starter code: def cake_slice(n):
	

Solutions:
def cake_slice(n):
	return (n ** 2 + n + 2) // 2


def cake_slice(n):
	return 0.5 * n ** 2 + 0.5 * n + 1


def cake_slice(n):
	return (n ** 2 + n) // 2 + 1


cake_slice = lambda n: sum(range(n + 1)) + 1


def cake_slice(n):
	sum = 1
	for i in range(n):
		sum += i + 1
	return sum


cake_slice = lambda n: (n + 1) * n / 2 + 1


def cake_slice(n):
	if n == 0:
		return 1
	else:
		return 2 + sum(iter(range(2, n + 1)))


def cake_slice(n):
	return -~(n * -~n >> 1)