結果

問題 No.1180 無限和
ユーザー karinohito
提出日時 2022-11-09 15:59:27
言語 C++17
(gcc 13.3.0 + boost 1.87.0)
結果
WA  
実行時間 -
コード長 227 bytes
コンパイル時間 1,849 ms
コンパイル使用メモリ 192,632 KB
最終ジャッジ日時 2025-02-08 19:26:19
ジャッジサーバーID
(参考情報)
judge4 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1
other AC * 21 WA * 19
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;
using ld = long double;
int main() {
    int n;
    cin>>n;
    ld an=1,p=atan2(ld(1),ld(1))*ld(4.0);
    p=p*p/ld(6);
    for(int i=0;i<n;i++)an*=p;
    cout<<floor(an/n)<<endl;
}
0