公式题。
#pragma comment(linker, "/STACK:1024000000,1024000000") #include<cstdio> #include<cstring> #include<cmath> #include<algorithm> #include<vector> #include<map> #include<set> #include<queue> #include<stack> #include<iostream> #include<ctime> using namespace std; typedef long long LL; const double pi=acos(-1.0); void File() { freopen("D:\\in.txt","r",stdin); freopen("D:\\out.txt","w",stdout); } int main() { double L; int T; scanf("%d",&T); while(T--) { scanf("%lf",&L); double s1=sqrt(7.0); double s2=asin(s1/4); double s3=4*asin(5.0*s1/16); double ans=L*L/4*(pi+s1-s2-s3); printf("%.2lf\n",ans); } return 0; }
时间: 2024-11-05 16:47:45