Submission #3775275
Source Code Expand
N,M=map(int,input().split()) flag = False v=[] x=[] y=[] for i in range(M): a,b=map(int,input().split()) if a==1: x.append(b) if b==N: y.append(a) for i in x: for j in y: if i==j: flag=True break if flag: print("POSSIBLE") break else: print("IMPOSSIBLE")
Submission Info
Submission Time | |
---|---|
Task | C - Cat Snuke and a Voyage |
User | moro |
Language | PyPy3 (2.4.0) |
Score | 0 |
Code Size | 362 Byte |
Status | TLE |
Exec Time | 2108 ms |
Memory | 58200 KB |
Judge Result
Set Name | Sample | All | ||||||
---|---|---|---|---|---|---|---|---|
Score / Max Score | 0 / 0 | 0 / 300 | ||||||
Status |
|
|
Set Name | Test Cases |
---|---|
Sample | example0, example1, example2, example3 |
All | example0, example1, example2, example3, last0, last1, many0, many1, rand0, rand1, rand2 |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
example0 | AC | 183 ms | 38512 KB |
example1 | AC | 175 ms | 38256 KB |
example2 | AC | 170 ms | 38256 KB |
example3 | AC | 173 ms | 38256 KB |
last0 | AC | 847 ms | 44248 KB |
last1 | AC | 880 ms | 44120 KB |
many0 | TLE | 2108 ms | 58200 KB |
many1 | TLE | 2108 ms | 58200 KB |
rand0 | AC | 656 ms | 43608 KB |
rand1 | AC | 848 ms | 43992 KB |
rand2 | AC | 592 ms | 43852 KB |