Time Exceeded
Code
n=int(input())
liN=list(map(int,input().split()))
m=int(input())
liM=list(map(int,input().split()))
res=[]
res=liN+liM
res.sort(reverse=True)
b=0
for i in liM:
if liM.count(i)==1:
idx=res.index(i)+1+liN.count(i)
print(idx,end=" ")
else:
idx=res.index(i)+1+liN.count(i)+b
print(idx,end=" ")
b+=1
Information
- Submit By
- Type
- Submission
- Problem
- P1049 Combined scoreboard
- Contest
- Brain Booster #3
- Language
- Python 3 (Python 3.12.3)
- Submit At
- 2024-05-06 16:28:44
- Judged At
- 2024-11-11 03:33:04
- Judged By
- Score
- 5
- Total Time
- ≥2092ms
- Peak Memory
- ≥17.234 MiB