Description
把一个直径 2n - 1个单位长的园画在 2n 的棋盘中央. 当n = 3时构造描绘如下:
写一个程序来确定有多少格子包含一部分的园, 有多少格子完全包含在园里面.
Input
每行包含一个非负且不大于150的整数n.
Output
对于每一个输入的n, 要求连续输出两行(格式如输出范例). 接着输出一个空白行来区别连续的两个输出.
Sample Input
3 4
Sample Output
In the case n = 3, 20 cells contain segments of the circle. There are 12 cells completely contained in the circle. In the case n = 4, 28 cells contain segments of the circle. There are 24 cells completely contained in the circle.
KEY:这个主要是数学问题,由于四个部分都是一样的,所以只要算个一个部分就可以了,详细看代码;







































