Submission #74115265
Source Code Expand
n,a,b=map(int,input().split())
c=input()
c=list(c)
q=0
for k in range(a,b+1):
for i in range(n):
j=i+k
if c[j]==c[i]:
q=q+1
if j == n-1:
break
print(q)
Submission Info
| Submission Time | |
|---|---|
| Task | C - Comfortable Distance |
| User | usuaji288 |
| Language | Python (PyPy 3.11-v7.3.20) |
| Score | 0 |
| Code Size | 190 Byte |
| Status | TLE |
| Exec Time | > 2000 ms |
| Memory | 114832 KiB |
Judge Result
| Set Name | Sample | All | ||||||
|---|---|---|---|---|---|---|---|---|
| Score / Max Score | 0 / 0 | 0 / 300 | ||||||
| Status |
|
|
| Set Name | Test Cases |
|---|---|
| Sample | sample00.txt, sample01.txt, sample02.txt |
| All | sample00.txt, sample01.txt, sample02.txt, testcase00.txt, testcase01.txt, testcase02.txt, testcase03.txt, testcase04.txt, testcase05.txt, testcase06.txt, testcase07.txt, testcase08.txt, testcase09.txt, testcase10.txt, testcase11.txt, testcase12.txt, testcase13.txt, testcase14.txt, testcase15.txt, testcase16.txt, testcase17.txt, testcase18.txt, testcase19.txt |
| Case Name | Status | Exec Time | Memory |
|---|---|---|---|
| sample00.txt | AC | 47 ms | 79744 KiB |
| sample01.txt | AC | 46 ms | 79824 KiB |
| sample02.txt | AC | 46 ms | 79528 KiB |
| testcase00.txt | AC | 46 ms | 79684 KiB |
| testcase01.txt | AC | 46 ms | 79660 KiB |
| testcase02.txt | TLE | > 2000 ms | 92556 KiB |
| testcase03.txt | TLE | > 2000 ms | 113384 KiB |
| testcase04.txt | TLE | > 2000 ms | 98420 KiB |
| testcase05.txt | TLE | > 2000 ms | 103532 KiB |
| testcase06.txt | TLE | > 2000 ms | 95656 KiB |
| testcase07.txt | TLE | > 2000 ms | 114204 KiB |
| testcase08.txt | TLE | > 2000 ms | 114404 KiB |
| testcase09.txt | TLE | > 2000 ms | 114628 KiB |
| testcase10.txt | TLE | > 2000 ms | 114156 KiB |
| testcase11.txt | TLE | > 2000 ms | 114320 KiB |
| testcase12.txt | AC | 66 ms | 111696 KiB |
| testcase13.txt | TLE | > 2000 ms | 113292 KiB |
| testcase14.txt | AC | 61 ms | 106180 KiB |
| testcase15.txt | TLE | > 2000 ms | 114680 KiB |
| testcase16.txt | AC | 67 ms | 112564 KiB |
| testcase17.txt | TLE | > 2000 ms | 114832 KiB |
| testcase18.txt | AC | 61 ms | 106040 KiB |
| testcase19.txt | TLE | > 2000 ms | 114116 KiB |