Code Submission Evaluation System Login

Datatähti 2016 alku

Start:2015-09-28 00:00:00
End:2015-10-12 00:00:00
 

Tasks | Scoreboard | Statistics


CSES - Datatähti 2016 alku - Results
History
2015-10-11 23:58:1047
2015-10-11 23:53:560
2015-10-11 23:44:4314
2015-10-11 01:05:300
2015-10-10 18:31:5714
2015-10-06 11:06:0347
2015-10-06 10:43:140
2015-10-06 10:33:130
2015-09-30 19:09:4214
2015-09-30 18:50:280
Task:Tontti
Sender:MusserO
Submission time:2015-10-11 23:53:56
Language:Python3
Status:READY
Score:0

Feedback

groupverdictscore
#1WRONG ANSWER0
#2RUNTIME ERROR0
#3RUNTIME ERROR0

Test results

testverdicttime (s)group
#1WRONG ANSWER0.08 / 1.001details
#2ACCEPTED0.08 / 1.001details
#3ACCEPTED0.08 / 1.001details
#4ACCEPTED0.07 / 1.001details
#5ACCEPTED0.08 / 1.001details
#6RUNTIME ERROR0.91 / 1.002details
#7RUNTIME ERROR0.91 / 1.002details
#8RUNTIME ERROR0.93 / 1.002details
#9RUNTIME ERROR0.93 / 1.002details
#10RUNTIME ERROR0.94 / 1.002details
#11RUNTIME ERROR0.92 / 1.003details
#12RUNTIME ERROR0.86 / 1.003details
#13RUNTIME ERROR0.89 / 1.003details
#14RUNTIME ERROR0.89 / 1.003details
#15RUNTIME ERROR0.89 / 1.003details

Code

v = 0
n, m, x = [int(z) for z in input().split(" ")]
r = [[[0 for i in range(m)] for j in range(n)] for k in range(min(n, m)+1)]
for i in range(n):
    s = input()
    for j in range(m):
        r[0][i][j] = 0
        r[1][i][j] = (s[j] == '*')
        if (r[1][i][j] == x): ++v
for k in range(2, min(n, m)):
    for i in range(k-1, n):
        for j in range(k-1, m):
            r[k][i][j] = r[1][i][j] + r[k-1][i-1][j] + r[k-1][i][j-1] -\
                        r[k-2][i-1][j-1] + r[1][i-k+1][j-k+1]
            if (r[k][i][j] == x): v+=1
print(v)

Test details

Test 1

Group: 1

Verdict: WRONG ANSWER

input
10 10 1
......*...
.......*..
*..*....*.
*....*....
...
view   save

correct output
94

view   save

user output
84

view   save

Test 2

Group: 1

Verdict: ACCEPTED

input
10 10 5
**********
**********
**********
**********
...
view   save

correct output
0

view   save

user output
0

view   save

Test 3

Group: 1

Verdict: ACCEPTED

input
10 10 10
**...*...*
*..*.**.*.
...**.*..*
*...**.*..
...
view   save

correct output
4

view   save

user output
4

view   save

Test 4

Group: 1

Verdict: ACCEPTED

input
10 10 5
****......
*.*.**..**
....*.*..*
...*.***..
...
view   save

correct output
16

view   save

user output
16

view   save

Test 5

Group: 1

Verdict: ACCEPTED

input
10 10 2
**.***..*.
...*.*....
.***.*...*
***.***..*
...
view   save

correct output
30

view   save

user output
30

view   save

Test 6

Group: 2

Verdict: RUNTIME ERROR

input
500 500 1
.................................
view   save

correct output
9552040

view   save

user output
(empty)

Test 7

Group: 2

Verdict: RUNTIME ERROR

input
500 500 5
.................................
view   save

correct output
1536063

view   save

user output
(empty)

Test 8

Group: 2

Verdict: RUNTIME ERROR

input
500 500 25000
**...*...**..*.*..*.**.*..*.*....
view   save

correct output
288

view   save

user output
(empty)

Test 9

Group: 2

Verdict: RUNTIME ERROR

input
500 500 12500
**.**.*..*...*.**...*.***........
view   save

correct output
786

view   save

user output
(empty)

Test 10

Group: 2

Verdict: RUNTIME ERROR

input
500 500 5000
.*.*.**..*.*.**.**..*..**...*....
view   save

correct output
1763

view   save

user output
(empty)

Test 11

Group: 3

Verdict: RUNTIME ERROR

input
2000 2000 1
.................................
view   save

correct output
489611392

view   save

user output
(empty)

Test 12

Group: 3

Verdict: RUNTIME ERROR

input
2000 2000 5
.................................
view   save

correct output
120725884

view   save

user output
(empty)

Test 13

Group: 3

Verdict: RUNTIME ERROR

input
2000 2000 400000
..*..**.**.**.*.***...**.*..**...
view   save

correct output
1849

view   save

user output
(empty)

Test 14

Group: 3

Verdict: RUNTIME ERROR

input
2000 2000 200000
***.*....*.*..*....**..*..*.*....
view   save

correct output
2665

view   save

user output
(empty)

Test 15

Group: 3

Verdict: RUNTIME ERROR

input
2000 2000 80000
**.**...*.***.**....**.*....*....
view   save

correct output
5587

view   save

user output
(empty)