結果
| 問題 |
No.49 算数の宿題
|
| コンテスト | |
| ユーザー |
とりゐ
|
| 提出日時 | 2023-06-06 14:30:29 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 39 ms / 5,000 ms |
| コード長 | 255 bytes |
| コンパイル時間 | 317 ms |
| コンパイル使用メモリ | 82,892 KB |
| 実行使用メモリ | 53,336 KB |
| 最終ジャッジ日時 | 2024-12-29 08:28:54 |
| 合計ジャッジ時間 | 1,407 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 10 |
ソースコード
s=input()
def number():
global i
tmp=0
while i<len(s) and '0'<=s[i]<='9':
tmp=10*tmp+int(s[i])
i+=1
return tmp
i=0
res=number()
while i!=len(s):
c=s[i]
i+=1
res2=number()
if c=='+':
res*=res2
else:
res+=res2
print(res)
とりゐ