CF-gym100338-A Shitália

standard input/output 

After suddenly becoming a billionaire, Shi adopted YOLO as his motto and decided to buy a small european island, which he named Shitalia. Many people decided to move to Shitalia to run away from the economic crisis, and then created the Shitalian mafia, led by Dom Shi.

The Shitalian economy is based on smuggling spoiled cheese, but, as you can imagine, there aren't many people interested in spoiled cheese. Therefore, Shi decided to earn money with land rental.

Shitalia is a star-shaped island. Shi is very picky, so he chose a Shi-regular n-star. An n-star is Shi-regular if there are n outer points andn inner points alternated. The outer points must lay on a circle with radius R and the inner points must lay on a circle with radius r and all the points must be equally spaced.

Print the area of the Shitalia.

 Shi-regular 6-star and 4-star.

Input

The first line contains three integers 3 ≤ n ≤ 201 ≤ R ≤ 106 and 1 ≤ r ≤ R, indicating the number of points of Shitalia, the radius of the outer circle and the radius of the inner circle.

Output

Print a single real number - the answer to the problem with absolute or relative error of at most 10 - 6.

Sample Input

Input
3 2 1
Output
5.1961524227
Input
4 4 2
Output
22.6274169980
Input
6 3 2
Output
18.0000000000

题目大意:给出一种多角星,外点在半径为R的圆上,内点在半径为r的圆上,求面积。
没什么难点直接上公式。
<script src="https://code.csdn.net/snippets/971499.js"></script>
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值