結果

問題 No.1180 無限和
ユーザー uni_pythonuni_python
提出日時 2020-08-30 22:04:50
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 74 ms / 1,000 ms
コード長 819 bytes
コンパイル時間 347 ms
コンパイル使用メモリ 86,616 KB
実行使用メモリ 71,764 KB
最終ジャッジ日時 2023-08-09 18:44:23
合計ジャッジ時間 6,229 ms
ジャッジサーバーID
(参考情報)
judge14 / judge15
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 73 ms
70,976 KB
testcase_01 AC 74 ms
71,488 KB
testcase_02 AC 73 ms
71,492 KB
testcase_03 AC 72 ms
71,508 KB
testcase_04 AC 71 ms
71,316 KB
testcase_05 AC 72 ms
71,348 KB
testcase_06 AC 71 ms
71,484 KB
testcase_07 AC 72 ms
71,324 KB
testcase_08 AC 72 ms
71,268 KB
testcase_09 AC 72 ms
71,324 KB
testcase_10 AC 70 ms
71,348 KB
testcase_11 AC 73 ms
71,376 KB
testcase_12 AC 71 ms
71,312 KB
testcase_13 AC 72 ms
71,392 KB
testcase_14 AC 71 ms
71,764 KB
testcase_15 AC 74 ms
71,336 KB
testcase_16 AC 73 ms
71,448 KB
testcase_17 AC 71 ms
71,420 KB
testcase_18 AC 72 ms
71,212 KB
testcase_19 AC 72 ms
71,328 KB
testcase_20 AC 71 ms
71,448 KB
testcase_21 AC 73 ms
71,484 KB
testcase_22 AC 73 ms
71,496 KB
testcase_23 AC 72 ms
71,276 KB
testcase_24 AC 71 ms
71,556 KB
testcase_25 AC 73 ms
71,496 KB
testcase_26 AC 73 ms
71,572 KB
testcase_27 AC 72 ms
71,348 KB
testcase_28 AC 72 ms
71,540 KB
testcase_29 AC 71 ms
71,568 KB
testcase_30 AC 72 ms
71,568 KB
testcase_31 AC 72 ms
71,388 KB
testcase_32 AC 72 ms
71,488 KB
testcase_33 AC 73 ms
71,376 KB
testcase_34 AC 71 ms
71,344 KB
testcase_35 AC 70 ms
71,216 KB
testcase_36 AC 73 ms
71,392 KB
testcase_37 AC 73 ms
71,344 KB
testcase_38 AC 72 ms
71,628 KB
testcase_39 AC 70 ms
71,632 KB
testcase_40 AC 72 ms
71,272 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input=sys.stdin.readline
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))


"""
知識0からだときつい
まずバーゼルは(pi^2)/6

これ,a2~aNまでは対称なのでa1をa2やらaNに置き換えても答えは同じはず.
差し替えたものを足して平均しても答えは同じになるはず.
全部を足すことで式をきれいにできる,というか同じようなものをいっぱい作れる

1/N * Σ...Σ ( 1/((a1^2)*B) ) + ... + ( 1/((an^2)*B) ) 
これは結局バーゼル問題の答えをN回かけている.
詳細は解説の通り
"""
def main():
    import math
    mod=10**9+7
    N=I()
    pi=math.pi
    ans=int((pow(pi,2*N))/(N*pow(6,N)))
    
    print(ans)
    
    



main()
0