Hello World
Tuesday, 8 May 2012
UVa 10432 Polygon Inside A Circle Solution
#include<stdio.h>
#include<math.h>
int main()
{
double r,n,ans;
while(scanf("%lf%lf",&r,&n)==2)
{
ans=r*r*n/2*sin(2.0*3.1415926535897932384626433832795/n);
printf("%.3lf\n",ans);
}
}
2 comments:
Unknown
12:44 am, May 31, 2017
what's the formula to get "ans",vaia?
Reply
Delete
Replies
Reply
Anonymous
11:40 pm, March 09, 2018
half of n r square sin 2 pi by n @007
Reply
Delete
Replies
Reply
Add comment
Load more...
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
what's the formula to get "ans",vaia?
ReplyDeletehalf of n r square sin 2 pi by n @007
ReplyDelete