WA求助
查看原帖
WA求助
793689
Ancap楼主2022/11/9 20:20
#include<bits/stdc++.h>
using namespace std;
int main()
{
	long double in,sum=1,count=1,temp;
	cin>>in;
	while(count<=in)
	{
	    count++;
	    temp*=count;
		sum+=1.0/temp;
	}
	cout<<fixed<<setprecision(10)<<sum;
}

测试点全WA。

2022/11/9 20:20
加载中...