Submission #18380610
Source Code Expand
n, x = map(int, input().split())
s = input()
for i in s:
if i == "o":
x += 1
elif x > 0:
x -= 1
print(x)
Submission Info
| Submission Time | |
|---|---|
| Task | B - Quizzes |
| User | hachy |
| Language | Python (3.8.2) |
| Score | 200 |
| Code Size | 137 Byte |
| Status | AC |
| Exec Time | 47 ms |
| Memory | 9268 KiB |
Judge Result
| Set Name | Sample | All | ||||
|---|---|---|---|---|---|---|
| Score / Max Score | 0 / 0 | 200 / 200 | ||||
| Status |
|
|
| Set Name | Test Cases |
|---|---|
| Sample | sample_01.txt, sample_02.txt, sample_03.txt |
| All | random_01.txt, random_02.txt, random_03.txt, random_04.txt, random_05.txt, random_06.txt, random_07.txt, sample_01.txt, sample_02.txt, sample_03.txt |
| Case Name | Status | Exec Time | Memory |
|---|---|---|---|
| random_01.txt | AC | 30 ms | 9008 KiB |
| random_02.txt | AC | 35 ms | 9036 KiB |
| random_03.txt | AC | 18 ms | 8840 KiB |
| random_04.txt | AC | 41 ms | 9268 KiB |
| random_05.txt | AC | 42 ms | 9180 KiB |
| random_06.txt | AC | 47 ms | 9196 KiB |
| random_07.txt | AC | 41 ms | 9264 KiB |
| sample_01.txt | AC | 16 ms | 8804 KiB |
| sample_02.txt | AC | 17 ms | 8796 KiB |
| sample_03.txt | AC | 16 ms | 9008 KiB |