結果

問題 No.544 Delete 7
ユーザー 330Xs330Xs
提出日時 2022-01-30 17:22:25
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 94 ms / 1,000 ms
コード長 378 bytes
コンパイル時間 1,343 ms
コンパイル使用メモリ 87,324 KB
実行使用メモリ 71,988 KB
最終ジャッジ日時 2023-09-02 01:41:51
合計ジャッジ時間 9,455 ms
ジャッジサーバーID
(参考情報)
judge11 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 90 ms
71,908 KB
testcase_01 AC 91 ms
71,512 KB
testcase_02 AC 91 ms
71,808 KB
testcase_03 AC 91 ms
71,904 KB
testcase_04 AC 91 ms
71,804 KB
testcase_05 AC 92 ms
71,824 KB
testcase_06 AC 91 ms
71,704 KB
testcase_07 AC 92 ms
71,792 KB
testcase_08 AC 93 ms
71,664 KB
testcase_09 AC 92 ms
71,476 KB
testcase_10 AC 90 ms
71,508 KB
testcase_11 AC 91 ms
71,912 KB
testcase_12 AC 91 ms
71,644 KB
testcase_13 AC 92 ms
71,868 KB
testcase_14 AC 93 ms
71,712 KB
testcase_15 AC 91 ms
71,560 KB
testcase_16 AC 91 ms
71,808 KB
testcase_17 AC 91 ms
71,760 KB
testcase_18 AC 93 ms
71,804 KB
testcase_19 AC 92 ms
71,968 KB
testcase_20 AC 90 ms
71,936 KB
testcase_21 AC 92 ms
71,832 KB
testcase_22 AC 92 ms
71,708 KB
testcase_23 AC 93 ms
71,824 KB
testcase_24 AC 94 ms
71,708 KB
testcase_25 AC 92 ms
71,720 KB
testcase_26 AC 91 ms
71,620 KB
testcase_27 AC 92 ms
71,888 KB
testcase_28 AC 94 ms
71,644 KB
testcase_29 AC 91 ms
71,808 KB
testcase_30 AC 92 ms
71,988 KB
testcase_31 AC 92 ms
71,808 KB
testcase_32 AC 90 ms
71,800 KB
testcase_33 AC 92 ms
71,768 KB
testcase_34 AC 90 ms
71,720 KB
testcase_35 AC 91 ms
71,808 KB
testcase_36 AC 92 ms
71,428 KB
testcase_37 AC 91 ms
71,720 KB
testcase_38 AC 90 ms
71,476 KB
testcase_39 AC 90 ms
71,476 KB
testcase_40 AC 90 ms
71,960 KB
testcase_41 AC 93 ms
71,792 KB
testcase_42 AC 91 ms
71,916 KB
testcase_43 AC 90 ms
71,988 KB
testcase_44 AC 90 ms
71,764 KB
testcase_45 AC 91 ms
71,964 KB
testcase_46 AC 91 ms
71,800 KB
testcase_47 AC 92 ms
71,840 KB
testcase_48 AC 90 ms
71,808 KB
testcase_49 AC 90 ms
71,840 KB
testcase_50 AC 89 ms
71,904 KB
testcase_51 AC 92 ms
71,816 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from collections import deque
n = list(map(str,input()))
a = []
b = deque()
for i in range(len(n)):
    if(n[i] == '7'):
        a.append('6')
        b.append('1')
    else:
        a.append(n[i])
        b.append('0')

while(len(b) > 0):
    if(b[0] == '0'):
        b.popleft()
    else:
        break
        
if(len(b) == 0):
    b = ['0']
    
print(''.join(a),''.join(b))
0