Black cells in a chessboard solution codechef

Black cells in a chessboard solution codechef

Read problem statements in Mandarin Chinese and Bengali.

Given nn (nn is even), determine the number of black cells in an n×nn×n chessboard.

Input Format

The only line of the input contains a single integer nn.

Output Format Black cells in a chessboard solution codechef

Output the number of black cells in an n×nn×n chessboard.

Constraints

  • 2n1002≤n≤100
  • nn is even

Sample Input 1 

8

Sample Output 1  Black cells in a chessboard solution codechef 

32

Explanation

There are 3232 black cells and 3232 white cells in an 8×88×8 chessboard. So the answer is 3232.

Leave a Comment