Submission #1294447
Source Code Expand
import itertools def main(): n, m = map(int, input().split()) x = sorted(list(map(int, input().split()))) y = sorted(list(map(int, input().split()))) s = 0 # x_len = 0 # y_len = 0 for e1 in itertools.combinations(x, 2): for e2 in itertools.combinations(y, 2): x_len = e1[0] - e1[1] y_len = e2[0] - e2[1] s += x_len * y_len print(s % (10 ** 9 + 7)) if __name__ == '__main__': main()
Submission Info
Submission Time | |
---|---|
Task | D - ### |
User | sira |
Language | Python (3.4.3) |
Score | 0 |
Code Size | 488 Byte |
Status | TLE |
Exec Time | 2104 ms |
Memory | 18556 KB |
Judge Result
Set Name | Sample | All | ||||||
---|---|---|---|---|---|---|---|---|
Score / Max Score | 0 / 0 | 0 / 500 | ||||||
Status |
|
|
Set Name | Test Cases |
---|---|
Sample | 0_000.txt, 0_001.txt |
All | 0_000.txt, 0_001.txt, max.txt, min.txt, mod.txt, n2.txt, rndA.txt, rndB.txt, rndC.txt, rndD.txt, rndE.txt, rndF.txt, rndG.txt, rndH.txt, rndI.txt, rndJ.txt, var.txt |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
0_000.txt | AC | 18 ms | 3064 KB |
0_001.txt | AC | 17 ms | 3064 KB |
max.txt | TLE | 2104 ms | 18396 KB |
min.txt | AC | 17 ms | 3064 KB |
mod.txt | TLE | 2104 ms | 14212 KB |
n2.txt | TLE | 2104 ms | 14212 KB |
rndA.txt | TLE | 2104 ms | 18556 KB |
rndB.txt | TLE | 2104 ms | 18556 KB |
rndC.txt | TLE | 2104 ms | 18556 KB |
rndD.txt | TLE | 2104 ms | 18556 KB |
rndE.txt | TLE | 2104 ms | 18556 KB |
rndF.txt | TLE | 2104 ms | 18556 KB |
rndG.txt | TLE | 2104 ms | 18556 KB |
rndH.txt | TLE | 2104 ms | 18556 KB |
rndI.txt | TLE | 2104 ms | 18556 KB |
rndJ.txt | TLE | 2104 ms | 18556 KB |
var.txt | TLE | 2104 ms | 18248 KB |