Submission #6495186
Source Code Expand
Copy
import copy N, K = list(map(int, input().split())) A = list(map(int, input().split())) pattern = [] l = [] for i in range(K): for a in A: l.append(a) idx = l.index(a) if idx < len(l)-1: l = l[:idx] if len(pattern) > 0 and pattern[0] == l: break else: pattern.append(copy.deepcopy(l)) ans = pattern[(K-1)%len(pattern)] print(" ".join(list(map(str, ans))))
Submission Info
Submission Time | |
---|---|
Task | B - Do Not Duplicate |
User | marble0117 |
Language | Python (3.4.3) |
Score | 0 |
Code Size | 436 Byte |
Status | TLE |
Exec Time | 2104 ms |
Memory | 26572 KB |
Judge Result
Set Name | Sample | All | ||||||
---|---|---|---|---|---|---|---|---|
Score / Max Score | 0 / 0 | 0 / 700 | ||||||
Status |
|
|
Set Name | Test Cases |
---|---|
Sample | sample-01.txt, sample-02.txt, sample-03.txt, sample-04.txt |
All | 01-01.txt, 01-02.txt, 01-03.txt, 01-04.txt, 01-05.txt, 01-06.txt, 01-07.txt, 01-08.txt, 01-09.txt, 01-10.txt, 01-11.txt, 01-12.txt, 01-13.txt, 01-14.txt, 01-15.txt, 01-16.txt, 01-17.txt, 01-18.txt, 01-19.txt, 01-20.txt, 01-21.txt, 01-22.txt, 01-23.txt, 01-24.txt, 01-25.txt, 01-26.txt, 01-27.txt, 01-28.txt, 01-29.txt, 01-30.txt, sample-01.txt, sample-02.txt, sample-03.txt, sample-04.txt |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
01-01.txt | AC | 29 ms | 3572 KB |
01-02.txt | TLE | 2104 ms | 8108 KB |
01-03.txt | TLE | 2104 ms | 9028 KB |
01-04.txt | TLE | 2104 ms | 21904 KB |
01-05.txt | TLE | 2104 ms | 6780 KB |
01-06.txt | TLE | 2104 ms | 23708 KB |
01-07.txt | TLE | 2104 ms | 19948 KB |
01-08.txt | TLE | 2104 ms | 14792 KB |
01-09.txt | TLE | 2104 ms | 22432 KB |
01-10.txt | TLE | 2104 ms | 23892 KB |
01-11.txt | TLE | 2104 ms | 14816 KB |
01-12.txt | TLE | 2104 ms | 12828 KB |
01-13.txt | TLE | 2104 ms | 15404 KB |
01-14.txt | AC | 157 ms | 15380 KB |
01-15.txt | AC | 295 ms | 23376 KB |
01-16.txt | TLE | 2104 ms | 24104 KB |
01-17.txt | TLE | 2104 ms | 25096 KB |
01-18.txt | TLE | 2104 ms | 23976 KB |
01-19.txt | TLE | 2104 ms | 26572 KB |
01-20.txt | TLE | 2104 ms | 26568 KB |
01-21.txt | TLE | 2104 ms | 26564 KB |
01-22.txt | TLE | 2104 ms | 26248 KB |
01-23.txt | TLE | 2104 ms | 26244 KB |
01-24.txt | TLE | 2104 ms | 26248 KB |
01-25.txt | TLE | 2104 ms | 26248 KB |
01-26.txt | TLE | 2104 ms | 26248 KB |
01-27.txt | TLE | 2104 ms | 26244 KB |
01-28.txt | AC | 256 ms | 25936 KB |
01-29.txt | AC | 326 ms | 25936 KB |
01-30.txt | TLE | 2104 ms | 25128 KB |
sample-01.txt | AC | 22 ms | 3444 KB |
sample-02.txt | AC | 22 ms | 3444 KB |
sample-03.txt | AC | 22 ms | 3444 KB |
sample-04.txt | AC | 22 ms | 3444 KB |