結果
問題 | No.53 悪の漸化式 |
ユーザー |
|
提出日時 | 2022-01-24 20:07:24 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 133 ms / 5,000 ms |
コード長 | 320 bytes |
コンパイル時間 | 243 ms |
コンパイル使用メモリ | 81,972 KB |
実行使用メモリ | 81,600 KB |
最終ジャッジ日時 | 2024-12-14 21:59:37 |
合計ジャッジ時間 | 3,595 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 20 |
ソースコード
import sysimport decimaldef input(): return sys.stdin.readline().rstrip()def main():decimal.getcontext().prec = 100A = [decimal.Decimal(4), decimal.Decimal(3)]N = int(input())for i in range(N-1):A.append((19*A[-1]-12*A[-2])/4)print(A[N])if __name__ == '__main__':main()