結果
| 問題 | No.193 筒の数式 |
| コンテスト | |
| ユーザー |
e-mon
|
| 提出日時 | 2015-04-29 21:43:42 |
| 言語 | Python3 (3.15.0 + numpy 2.5.4 + scipy 1.18.1 + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 25 ms / 1,000 ms |
| + 870µs | |
| コード長 | 367 bytes |
| 記録 | |
| コンパイル時間 | 71 ms |
| コンパイル使用メモリ | 15,104 KB |
| 実行使用メモリ | 10,880 KB |
| 最終ジャッジ日時 | 2026-10-14 17:41:18 |
| 合計ジャッジ時間 | 2,077 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge4_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 18 |
ソースコード
#!/usr/bin/env python
# -*- coding: utf-8 -*-
S = input()
ans = -10**10
for i in range(len(S)):
e = S[i+1:] + S[:i+1]
if e[0] in ['+','-'] or e[-1] in ['+','-']:
continue
e = ''.join([str(int(s)) if s.isdigit() is True else s for s in ''.join([' ' + x + ' ' if x in ['+','-'] else x for x in e]).split()])
ans = max(ans,eval(e))
print(ans)
e-mon