UVA 10432 Solution

Hints:



Solve in c:

#include<stdio.h>
#include<math.h>
int main()
{
    double r,n,a;
    while(scanf("%lf%lf",&r,&n)!=EOF)
    {
        a=n*r*r*sin((2*M_PI)/n)/2.0;
        printf("%.3lf\n",a);
    }
}

No comments

Most View Post

Recent post

Codeforces Round 925 (Div. 3) 1931D. Divisible Pairs Solution

    Problem Link  :   https://codeforces.com/contest/1931/problem/D S olution in C++: /// Author : AH_Tonmoy #include < bits / stdc ++. ...

Powered by Blogger.