結果
問題 |
No.1466 I am not genius.
|
ユーザー |
![]() |
提出日時 | 2021-04-02 23:15:55 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 1,321 bytes |
コンパイル時間 | 938 ms |
コンパイル使用メモリ | 86,812 KB |
実行使用メモリ | 6,824 KB |
最終ジャッジ日時 | 2024-12-23 21:51:23 |
合計ジャッジ時間 | 1,911 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 1 WA * 25 |
ソースコード
#include <cmath> #include <iomanip> #include <iostream> #include <limits> #include <map> #include <set> #include <string> #include <vector> using namespace std; typedef long long ll; #define rep(i, init, end) for(ll i = init; i < end; i++) #define REP(i, init, end) for(ll i = init; i < end + 1; i++) #define rev(i, end, init) for(ll i = init - 1; i >= end; i--) #define REV(i, end, init) for(ll i = init; i >= end; i--) #define PI 3.14159265359 #define EPS 0.0000000001 #define MOD 1000000007 //cout << std::fixed << std::setprecision(15) << y << endl; double g(ll n){ double ans = 1.0; for(ll i = 1; i <= n; i++){ ans *= (double)i; } return ans; } int main(){ double x; cin >> x; double sum[10000]; double a, b, c; ll p = 0; a = 1.0, b = 1.0, c = 1123.0 / 1103.0; sum[0] = a * b * c; while(abs(sum[p]) > 1e-20){ p++; a *= -1.0 * pow(22, 5) * pow(882, 3) / (pow(49, 5) * 4.0 * 99.0); b = 1.0 / g(4 * p - 2) * (4 * p - 2); c = (1123.0 + 21460.0 * (double)p) / (1103.0 + 26390.0 * (double)p); sum[p] = a * b * c; } double ans = 24.0 / 882.0 * sqrt(99) * x; double sumAll = 0; rep(i, 0, p){ sumAll += sum[p]; } cout << fixed << setprecision(20) << ans * sumAll << endl; return 0; }