結果
問題 | No.632 穴埋め門松列 |
ユーザー | pluto77 |
提出日時 | 2018-01-22 09:18:28 |
言語 | Python2 (2.7.18) |
結果 |
WA
|
実行時間 | - |
コード長 | 482 bytes |
コンパイル時間 | 1,097 ms |
コンパイル使用メモリ | 6,652 KB |
実行使用メモリ | 5,992 KB |
最終ジャッジ日時 | 2023-08-26 20:18:57 |
合計ジャッジ時間 | 1,306 ms |
ジャッジサーバーID (参考情報) |
judge13 / judge15 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 11 ms
5,800 KB |
testcase_01 | AC | 10 ms
5,884 KB |
testcase_02 | WA | - |
testcase_03 | WA | - |
testcase_04 | AC | 10 ms
5,880 KB |
testcase_05 | AC | 10 ms
5,992 KB |
ソースコード
#yuki632 s=map(str,raw_input().split()) if s[1]=='?': x=max(int(s[0]),int(s[2]))+1 y=min(int(s[0]),int(s[2]))-1 if y>0: print str(x)+str(y) else: print str(x) elif s[0]=='?': if int(s[1])>int(s[2]): if int(s[1])-int(s[2])==1: print str(int(s[2])-1) else: print str(int(s[1])-1) else: print str(int(s[2])+1) else: if int(s[1])>int(s[0]): if int(s[1])-int(s[0])==1: print str(int(s[0])-1) else: print str(int(s[1])-1) else: print str(int(s[0])+1)