結果
| 問題 |
No.1118 sin(x)/xの二乗和
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2020-07-17 22:25:57 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 394 bytes |
| コンパイル時間 | 1,920 ms |
| コンパイル使用メモリ | 193,520 KB |
| 最終ジャッジ日時 | 2025-01-11 22:56:02 |
|
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | WA * 20 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
using ll=long long;
const long double eps = 1e-10;
int main() {
long double x;
cin >> x;
long double ans = 0;
for(int i=0;i<int(1e5)+5;i++){
if(i +x <= eps){
ans += 1.0;
continue;
}
ans += powl(sinl(x+i)/(x+i),2.0);
}
cout << setprecision(20) <<ans << endl;
return 0;
}