結果
| 問題 | No.491 10^9+1と回文 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2017-03-10 23:58:38 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 339 bytes |
| 記録 | |
| コンパイル時間 | 202 ms |
| コンパイル使用メモリ | 12,672 KB |
| 実行使用メモリ | 17,820 KB |
| 最終ジャッジ日時 | 2024-06-24 09:09:24 |
| 合計ジャッジ時間 | 2,832 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | TLE * 1 -- * 102 |
ソースコード
def check(n):
ok = 1
s = str(n)
L = len(s)
for i in range(L):
if s[i] != s[L-1-i]:
ok = 0
return ok
def main():
A = 10**9+1
n = int(input())
now = A
ct = 0
while now < n:
ct += check(now)
now += A
return ct
if __name__ == '__main__':
print(main())