Task: | Merkkijono |
Sender: | Kisse |
Submission time: | 2018-01-18 15:15:11 +0200 |
Language: | Python3 |
Status: | READY |
Result: | 0 |
group | verdict | score |
---|---|---|
#1 | OUTPUT LIMIT EXCEEDED | 0 |
test | verdict | time | |
---|---|---|---|
#1 | ACCEPTED | 0.07 s | details |
#2 | OUTPUT LIMIT EXCEEDED | 0.00 s | details |
#3 | OUTPUT LIMIT EXCEEDED | 0.00 s | details |
#4 | OUTPUT LIMIT EXCEEDED | 0.00 s | details |
#5 | OUTPUT LIMIT EXCEEDED | 0.00 s | details |
Code
ABC = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" String = input() MoveList = [] I = 0 while 42: print(String) if String == ABC: break if (ABC.index(String[I]) - ABC.index(String[I + 1]) > 0): String = String.replace(String[I:I + 2], String[I + 1] + String[I]) MoveList.append("SWAP") String = (String[-1] + String[0:-1]) MoveList.append("MOVE") I = (I + 1) % 25 print(len(MoveList)) for L in MoveList: print(L)
Test details
Test 1
Verdict: ACCEPTED
input |
---|
ABCDEFGHIJKLMNOPQRSTUVWXYZ |
correct output |
---|
0 |
user output |
---|
ABCDEFGHIJKLMNOPQRSTUVWXYZ 0 |
Test 2
Verdict: OUTPUT LIMIT EXCEEDED
input |
---|
ZYXWVUTSRQPONMLKJIHGFEDCBA |
correct output |
---|
923 MOVE MOVE SWAP MOVE ... |
user output |
---|
(empty) |
Test 3
Verdict: OUTPUT LIMIT EXCEEDED
input |
---|
RPJMFWBHYQOTXUAENLDGZISCVK |
correct output |
---|
611 SWAP MOVE MOVE SWAP ... |
user output |
---|
(empty) |
Test 4
Verdict: OUTPUT LIMIT EXCEEDED
input |
---|
GWJSPBHANMXYFLKIDORVUCEZQT |
correct output |
---|
659 MOVE SWAP MOVE SWAP ... |
user output |
---|
(empty) |
Test 5
Verdict: OUTPUT LIMIT EXCEEDED
input |
---|
BJYNFLKEIUCZMQHRAXOGWPSDTV |
correct output |
---|
624 MOVE SWAP MOVE SWAP ... |
user output |
---|
(empty) |