| Task: | Tulkki |
| Sender: | adex720 |
| Submission time: | 2025-10-31 21:27:41 +0200 |
| Language: | Python3 (CPython3) |
| Status: | READY |
| Result: | 0 |
| subtask | verdict | score |
|---|---|---|
| #1 | RUNTIME ERROR | 0 |
| #2 | RUNTIME ERROR | 0 |
| #3 | RUNTIME ERROR | 0 |
| test | verdict | time | subtask | |
|---|---|---|---|---|
| #1 | RUNTIME ERROR | 0.02 s | 1, 2, 3 | details |
| #2 | RUNTIME ERROR | 0.02 s | 1, 2, 3 | details |
| #3 | RUNTIME ERROR | 0.02 s | 1, 2, 3 | details |
| #4 | RUNTIME ERROR | 0.02 s | 1, 2, 3 | details |
| #5 | RUNTIME ERROR | 0.02 s | 1, 2, 3 | details |
| #6 | RUNTIME ERROR | 0.02 s | 1, 2, 3 | details |
| #7 | RUNTIME ERROR | 0.02 s | 2, 3 | details |
| #8 | RUNTIME ERROR | 0.02 s | 2, 3 | details |
| #9 | RUNTIME ERROR | 0.02 s | 2, 3 | details |
| #10 | RUNTIME ERROR | 0.02 s | 2, 3 | details |
| #11 | RUNTIME ERROR | 0.02 s | 2, 3 | details |
| #12 | RUNTIME ERROR | 0.02 s | 2, 3 | details |
| #13 | RUNTIME ERROR | 0.02 s | 3 | details |
| #14 | RUNTIME ERROR | 0.02 s | 3 | details |
| #15 | RUNTIME ERROR | 0.02 s | 3 | details |
| #16 | RUNTIME ERROR | 0.02 s | 3 | details |
| #17 | RUNTIME ERROR | 0.02 s | 3 | details |
| #18 | RUNTIME ERROR | 0.02 s | 3 | details |
Code
import sys
komennot = []
for x in sys.stdin:
for y in x.split(None):
ind = y.find('#')
if ind == -1:
komennot.append(y)
elif ind > 0:
komennot.append(y.split('#')[0])
arvot = [0]*27
koodi = "arvot=[0]*27"
sisennys = 0
i = -1
n = len(komennot)-1
while i < n:
i+=1
if komennot[i] == '(':
sisennys+=1
continue
if komennot[i] == ')':
sisennys-=1
continue
koodi += '\n' + ' ' * sisennys
index = ord(komennot[i+1]) - ord('A')
if komennot[i] == 'C':
koodi += f'arvot[{index}]=0'
elif komennot[i] == 'I':
koodi += f'arvot[{index}]+=1'
elif komennot[i] == 'P':
koodi += f'print(arvot[{index}])'
elif komennot[i] == 'R':
koodi += f'for j{i} in range(arvot[{index}]):'
print(koodi)
eval(koodi)Test details
Test 1 (public)
Subtask: 1, 2, 3
Verdict: RUNTIME ERROR
| input |
|---|
| PRINT X INCREASE X PRINT X INCREASE X PRINT X ... |
| correct output |
|---|
| 0 1 2 0 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 8 foundTest 2 (public)
Subtask: 1, 2, 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE X # aybabtu PRINT X INCREASE # test ... |
| correct output |
|---|
| 1 3 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 7 foundTest 3 (public)
Subtask: 1, 2, 3
Verdict: RUNTIME ERROR
| input |
|---|
| # Create number 3 INCREASE X INCREASE X INCREASE X ... |
| correct output |
|---|
| 3 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 6 foundTest 4 (public)
Subtask: 1, 2, 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE A PRINT A INCREASE B PRINT B INCREASE C ... |
| correct output |
|---|
| 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ... |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 5 foundTest 5 (public)
Subtask: 1, 2, 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE X INCREASE X INCREASE X INCREASE X INCREASE X ... |
| correct output |
|---|
| 999 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 8 foundTest 6 (public)
Subtask: 1, 2, 3
Verdict: RUNTIME ERROR
| input |
|---|
| PRINT X PRINT X PRINT X PRINT X PRINT X ... |
| correct output |
|---|
| 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ... |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 5 foundTest 7 (public)
Subtask: 2, 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE A INCREASE A INCREASE A INCREASE A INCREASE A ... |
| correct output |
|---|
| 5 5 5 5 5 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 8 foundTest 8 (public)
Subtask: 2, 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE A INCREASE A INCREASE A INCREASE A INCREASE A ... |
| correct output |
|---|
| 0 0 0 0 0 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 8 foundTest 9 (public)
Subtask: 2, 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE A INCREASE A INCREASE A INCREASE A INCREASE A ... |
| correct output |
|---|
| 6 7 8 9 10 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 8 foundTest 10 (public)
Subtask: 2, 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE A INCREASE A INCREASE A INCREASE A INCREASE A ... |
| correct output |
|---|
| 5 5 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 8 foundTest 11 (public)
Subtask: 2, 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE A INCREASE A INCREASE A INCREASE A INCREASE A ... |
| correct output |
|---|
| 20 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 8 foundTest 12 (public)
Subtask: 2, 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE A INCREASE A INCREASE B INCREASE B ... |
| correct output |
|---|
| 42 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 8 foundTest 13 (public)
Subtask: 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE A INCREASE A INCREASE A INCREASE A INCREASE A ... |
| correct output |
|---|
| 1 2 2 3 3 3 4 4 4 4 5 5 5 5 5 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 8 foundTest 14 (public)
Subtask: 3
Verdict: RUNTIME ERROR
| input |
|---|
| # Create number 3 INCREASE A INCREASE A INCREASE... |
| correct output |
|---|
| 12 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 6 foundTest 15 (public)
Subtask: 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE X INCREASE X INCREASE X INCREASE X INCREASE X ... |
| correct output |
|---|
| 531441 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 8 foundTest 16 (public)
Subtask: 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE A INCREASE A INCREASE A INCREASE A INCREASE A ... |
| correct output |
|---|
| 1337 |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 8 foundTest 17 (public)
Subtask: 3
Verdict: RUNTIME ERROR
| input |
|---|
| INCREASE A INCREASE A REPEAT A TIMES ( REPEAT A TIMES ( ... |
| correct output |
|---|
| 1 2 1 2 1 1 3 4 3 4 3 4 3 4 3 ... |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 8 foundTest 18 (public)
Subtask: 3
Verdict: RUNTIME ERROR
| input |
|---|
| # Efficient algorithm for find... |
| correct output |
|---|
| 2 3 5 7 11 13 17 19 23 29 31 3... |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "/box/input/code.py", line 30, in <module>
index = ord(komennot[i+1]) - ord('A')
TypeError: ord() expected a character, but string of length 9 found