| Task: | Monikulmio |
| Sender: | poppendop |
| Submission time: | 2025-11-07 18:11:03 +0200 |
| Language: | Python3 (PyPy3) |
| Status: | READY |
| Result: | 0 |
| group | verdict | score |
|---|---|---|
| #1 | RUNTIME ERROR | 0 |
| test | verdict | time | score | |
|---|---|---|---|---|
| #1 | RUNTIME ERROR | 0.07 s | 0 | details |
| #2 | RUNTIME ERROR | 0.07 s | 0 | details |
| #3 | RUNTIME ERROR | 0.07 s | 0 | details |
| #4 | RUNTIME ERROR | 0.07 s | 0 | details |
| #5 | RUNTIME ERROR | 0.07 s | 0 | details |
| #6 | RUNTIME ERROR | 0.07 s | 0 | details |
| #7 | RUNTIME ERROR | 0.07 s | 0 | details |
| #8 | RUNTIME ERROR | 0.07 s | 0 | details |
| #9 | RUNTIME ERROR | 0.13 s | 0 | details |
| #10 | RUNTIME ERROR | 0.16 s | 0 | details |
Code
# första raden
n,m,k = (int(x) for x in input().split())
lista = []
punkter = []
for i in range(n):
lista.append([])
rad = lista[i]
for j in range(m):
rad.append("")
rad[j] = "#"
for i in range(k):
# de kvarvarande raderna
q,r = (int(x) for x in input().split())
rad = lista[q-1]
rad[r-1] = "*"
punkter.append((str(q)+" "+str(r)))
# här ska sättas in linjer
for i in range(len(punkter)):
pX,pY = (int(x) for x in punkter[i].split())
var = i+1
if i+1 == len(punkter):
var = 0
nX,nY = (int(x) for x in punkter[var].split())
if pX == nX:
rad = lista[pX-1]
if pY > nY:
for j in range(0,pY-nY-1):
rad[nY+j] = "="
else:
for j in range(0,nY-pY-1):
rad[pY+j] = "="
elif pY == nY:
kolumn = pY -1
if pX > nX:
rad = pX -2
while rad >= nX:
lista[rad][kolumn] = "|"
rad -= 1
else:
rad = nX -2
while rad >= pX:
lista[rad][kolumn] = "|"
rad -= 1
elif nY-pY == nX-pX:
if pX > nX:
rad = pX -2
kolumn = pY -2
while rad >= nX:
lista[rad][kolumn] = "\\"
rad -= 1
kolumn -= 1
else:
rad = nX-2
kolumn = nY -2
while rad >= pX:
lista[rad][kolumn] = "\\"
rad -= 1
kolumn -= 1
else:
if pX > nX:
rad = pX -2
kolumn = pY
while rad >= nX:
lista[rad][kolumn] = "/"
rad -= 1
kolumn += 1
else:
rad = nX -2
kolumn = nY
while rad >= pX:
lista[rad][kolumn] = "/"
rad -= 1
kolumn += 1
# kolla om inuti
def testa(x,y):
if lista[x][y] == "." or lista[x][y] == "#":
if len(lista[x]) > y:
if lista[x][y+1] == "#":
lista[x][y+1] == "."
testa(x,y+1)
if y>0:
if lista[x][y-1] == "#":
lista[x][y-1] == "."
testa(x,y-1)
if len(lista) > x:
if lista[x+1][y] == "#":
lista[x+1][y] == "."
testa(x+1,y)
if x>0:
if lista[x-1][y] == "#":
lista[x-1][y] = "."
testa(x-1,y)
for i in range(round(n/3)):
if lista[3*i][0] == "#":
lista[3*1][0] = "."
testa(3*i,0)
for i in range(round(m/3)):
if lista[0][3*i] == "#":
lista[0][3*1] = "."
testa(0,3*i)
# printa ut svaren
for i in range(len(lista)):
text = ""
for j in range(len(lista[i])):
text = str(text)+lista[i][j]
print(text)Test details
Test 1 (public)
Verdict: RUNTIME ERROR
| input |
|---|
| 8 9 5 5 2 2 5 5 8 7 8 ... |
| correct output |
|---|
| ......... ....*.... .../#\... ../###\.. .*#####*. ... |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "input/code.py", line 97, in <module>
testa(3*i,0)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
[Previous line repeated 5 more times]
File "input/code.py", line 79, in testa
if lista[x][y+1] == "#":
IndexError: list index out of rangeTest 2 (public)
Verdict: RUNTIME ERROR
| input |
|---|
| 20 40 4 5 10 5 30 15 30 15 10 |
| correct output |
|---|
| ................................. |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "input/code.py", line 97, in <module>
testa(3*i,0)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
[Previous line repeated 36 more times]
File "input/code.py", line 79, in testa
if lista[x][y+1] == "#":
IndexError: list index out of rangeTest 3 (public)
Verdict: RUNTIME ERROR
| input |
|---|
| 20 40 29 8 7 13 2 14 2 9 7 ... |
| correct output |
|---|
| ................................. |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "input/code.py", line 97, in <module>
testa(3*i,0)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
[Previous line repeated 36 more times]
File "input/code.py", line 79, in testa
if lista[x][y+1] == "#":
IndexError: list index out of rangeTest 4 (public)
Verdict: RUNTIME ERROR
| input |
|---|
| 20 40 14 5 12 5 25 8 28 13 28 ... |
| correct output |
|---|
| ................................. |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "input/code.py", line 97, in <module>
testa(3*i,0)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
[Previous line repeated 36 more times]
File "input/code.py", line 79, in testa
if lista[x][y+1] == "#":
IndexError: list index out of rangeTest 5 (public)
Verdict: RUNTIME ERROR
| input |
|---|
| 20 40 12 3 20 7 16 7 9 11 13 ... |
| correct output |
|---|
| ................................. |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "input/code.py", line 97, in <module>
testa(3*i,0)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
[Previous line repeated 36 more times]
File "input/code.py", line 79, in testa
if lista[x][y+1] == "#":
IndexError: list index out of rangeTest 6 (public)
Verdict: RUNTIME ERROR
| input |
|---|
| 9 35 33 2 3 2 8 4 8 4 5 ... |
| correct output |
|---|
| ................................. |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "input/code.py", line 97, in <module>
testa(3*i,0)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
[Previous line repeated 31 more times]
File "input/code.py", line 79, in testa
if lista[x][y+1] == "#":
IndexError: list index out of rangeTest 7 (public)
Verdict: RUNTIME ERROR
| input |
|---|
| 30 100 69 6 10 6 14 7 14 7 18 ... |
| correct output |
|---|
| ................................. |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "input/code.py", line 97, in <module>
testa(3*i,0)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
[Previous line repeated 96 more times]
File "input/code.py", line 79, in testa
if lista[x][y+1] == "#":
IndexError: list index out of rangeTest 8 (public)
Verdict: RUNTIME ERROR
| input |
|---|
| 40 60 192 11 3 11 5 10 6 11 7 ... |
| correct output |
|---|
| ................................. |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "input/code.py", line 97, in <module>
testa(3*i,0)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
[Previous line repeated 56 more times]
File "input/code.py", line 79, in testa
if lista[x][y+1] == "#":
IndexError: list index out of rangeTest 9 (public)
Verdict: RUNTIME ERROR
| input |
|---|
| 50 100 142 1 1 1 7 1 11 1 14 ... |
| correct output |
|---|
| *=====*===*==*................... |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "input/code.py", line 97, in <module>
testa(3*i,0)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code...Test 10 (public)
Verdict: RUNTIME ERROR
| input |
|---|
| 100 100 1000 10 1 4 7 1 4 1 9 ... |
| correct output |
|---|
| ...*====*........................ |
| user output |
|---|
| (empty) |
Error:
Traceback (most recent call last):
File "input/code.py", line 97, in <module>
testa(3*i,0)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code.py", line 81, in testa
testa(x,y+1)
File "input/code.py", line 85, in testa
testa(x,y-1)
File "input/code...