Submission #1443539
Source Code Expand
N=int(input()) l=[int(input()) for _ in range(N)] cnt=0 if(N<3): if N==1:print("0") elif l[1]>l[2]:print("1") else:print("0") for _ in range(N): for i in range(N-2): if l[i]>l[i+2]: l[i], l[i + 2] = l[i + 2], l[i] for _ in range(N): for i in range(N-1): if(l[i]>l[i+1]): l[i],l[i+1]=l[i+1],l[i] cnt+=1 print(cnt)
Submission Info
Submission Time | |
---|---|
Task | C - BBuBBBlesort! |
User | irobe_sama |
Language | Python (3.4.3) |
Score | 0 |
Code Size | 406 Byte |
Status | RE |
Exec Time | 2104 ms |
Memory | 7084 KB |
Judge Result
Set Name | Sample | All | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
Score / Max Score | 0 / 0 | 0 / 600 | ||||||||||
Status |
|
|
Set Name | Test Cases |
---|---|
Sample | s1.txt, s2.txt |
All | 01.txt, 02.txt, 03.txt, 04.txt, 05.txt, 06.txt, 07.txt, 08.txt, 09.txt, 10.txt, 11.txt, 12.txt, 13.txt, 14.txt, 15.txt, 16.txt, 17.txt, 18.txt, 19.txt, 20.txt, 21.txt, 22.txt, s1.txt, s2.txt |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
01.txt | TLE | 2104 ms | 7064 KB |
02.txt | TLE | 2104 ms | 7072 KB |
03.txt | TLE | 2104 ms | 7068 KB |
04.txt | TLE | 2104 ms | 7072 KB |
05.txt | TLE | 2104 ms | 7064 KB |
06.txt | TLE | 2104 ms | 7084 KB |
07.txt | TLE | 2104 ms | 7084 KB |
08.txt | TLE | 2104 ms | 7080 KB |
09.txt | TLE | 2104 ms | 7080 KB |
10.txt | TLE | 2104 ms | 7084 KB |
11.txt | TLE | 2104 ms | 7064 KB |
12.txt | TLE | 2104 ms | 7000 KB |
13.txt | TLE | 2104 ms | 7080 KB |
14.txt | TLE | 2104 ms | 7084 KB |
15.txt | TLE | 2104 ms | 7064 KB |
16.txt | TLE | 2104 ms | 7084 KB |
17.txt | TLE | 2104 ms | 7084 KB |
18.txt | WA | 17 ms | 3064 KB |
19.txt | RE | 17 ms | 3064 KB |
20.txt | RE | 17 ms | 3064 KB |
21.txt | AC | 17 ms | 3064 KB |
22.txt | AC | 17 ms | 3064 KB |
s1.txt | AC | 17 ms | 3064 KB |
s2.txt | AC | 17 ms | 3064 KB |