結果
| 問題 | No.3388 Sum of Function |
| コンテスト | |
| ユーザー |
yt142857
|
| 提出日時 | 2025-11-20 15:30:29 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 64 ms / 2,000 ms |
| + 351µs | |
| コード長 | 257 bytes |
| 記録 | |
| コンパイル時間 | 245 ms |
| コンパイル使用メモリ | 95,976 KB |
| 実行使用メモリ | 82,560 KB |
| 最終ジャッジ日時 | 2026-07-17 00:35:54 |
| 合計ジャッジ時間 | 3,507 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 23 |
ソースコード
def f(x):
return x**3-x**2+x+1
def Is_Prime(x):
if x == 1:
return False
for i in range(2,x):
if x%i==0:
return False
return True
a,b = map(int,input().split())
ans = 0
for i in range(a,b+1):
if Is_Prime(i):
ans += f(i)
print(ans)
yt142857