Submission #741958

# Submission time Handle Problem Language Result Execution time Memory
741958 2023-05-15T08:26:12 Z haydendoo Art Class (IOI13_artclass) C++17
0 / 100
57 ms 6520 KB
#include <bits/stdc++.h>
#include "artclass.h"
using namespace std;

int style(int h, int w, int r[500][500], int g[500][500], int b[500][500]) {
	int adjr=0,adjg=0,adjb=0;
	for(int i=0; i<h; ++i) {
		for(int j=0; j<w; ++j) {
			if(i) {
				adjr+=abs(r[i][j]-r[i-1][j]);
				adjg+=abs(g[i][j]-g[i-1][j]);
				adjb+=abs(b[i][j]-b[i-1][j]);
			}
			if(j) {
				adjr+=abs(r[i][j]-r[i][j-1]);
				adjg+=abs(g[i][j]-g[i][j-1]);
				adjb+=abs(b[i][j]-b[i][j-1]); 
			} 
		} 
	} 
	long double contrast = ((long double) adjr+adjg+adjb) / ((long double) h*w);
	if(contrast<=25.0) return 4;
	assert(0);
	if(contrast>=130.0) return 3;
	assert(0);
	return 1;
} 
# Verdict Execution time Memory Grader output
1 Runtime error 37 ms 6348 KB Execution killed with signal 6
2 Correct 43 ms 3148 KB Output is correct
3 Runtime error 40 ms 6316 KB Execution killed with signal 6
4 Runtime error 40 ms 6376 KB Execution killed with signal 6
5 Runtime error 39 ms 4856 KB Execution killed with signal 6
6 Runtime error 32 ms 4264 KB Execution killed with signal 6
7 Runtime error 37 ms 4796 KB Execution killed with signal 6
8 Correct 41 ms 3172 KB Output is correct
9 Correct 36 ms 3140 KB Output is correct
10 Runtime error 45 ms 6376 KB Execution killed with signal 6
11 Runtime error 23 ms 2900 KB Execution killed with signal 6
12 Incorrect 47 ms 3172 KB Output isn't correct
13 Runtime error 42 ms 6360 KB Execution killed with signal 6
14 Runtime error 27 ms 3760 KB Execution killed with signal 6
15 Runtime error 39 ms 5088 KB Execution killed with signal 6
16 Correct 40 ms 3152 KB Output is correct
17 Correct 32 ms 3192 KB Output is correct
18 Runtime error 48 ms 6348 KB Execution killed with signal 6
19 Runtime error 11 ms 1620 KB Execution killed with signal 6
20 Runtime error 40 ms 5200 KB Execution killed with signal 6
21 Runtime error 57 ms 5116 KB Execution killed with signal 6
22 Runtime error 45 ms 6380 KB Execution killed with signal 6
23 Runtime error 50 ms 6348 KB Execution killed with signal 6
24 Incorrect 47 ms 3120 KB Output isn't correct
25 Runtime error 43 ms 5296 KB Execution killed with signal 6
26 Incorrect 30 ms 3156 KB Output isn't correct
27 Correct 36 ms 3156 KB Output is correct
28 Runtime error 43 ms 6320 KB Execution killed with signal 6
29 Runtime error 49 ms 6264 KB Execution killed with signal 6
30 Correct 11 ms 3204 KB Output is correct
31 Runtime error 42 ms 5320 KB Execution killed with signal 6
32 Correct 38 ms 3136 KB Output is correct
33 Correct 31 ms 3212 KB Output is correct
34 Incorrect 46 ms 3224 KB Output isn't correct
35 Correct 38 ms 3212 KB Output is correct
36 Incorrect 48 ms 3228 KB Output isn't correct
37 Runtime error 39 ms 5032 KB Execution killed with signal 6
38 Runtime error 32 ms 6348 KB Execution killed with signal 6
39 Runtime error 44 ms 5280 KB Execution killed with signal 6
40 Runtime error 42 ms 6292 KB Execution killed with signal 6
41 Runtime error 42 ms 5276 KB Execution killed with signal 6
42 Runtime error 32 ms 4300 KB Execution killed with signal 6
43 Correct 37 ms 3208 KB Output is correct
44 Runtime error 43 ms 5368 KB Execution killed with signal 6
45 Runtime error 42 ms 5012 KB Execution killed with signal 6
46 Runtime error 37 ms 6284 KB Execution killed with signal 6
47 Runtime error 41 ms 5112 KB Execution killed with signal 6
48 Correct 28 ms 3148 KB Output is correct
49 Runtime error 45 ms 5544 KB Execution killed with signal 6
50 Correct 31 ms 3168 KB Output is correct
51 Runtime error 42 ms 5472 KB Execution killed with signal 6
52 Correct 27 ms 3156 KB Output is correct
53 Runtime error 20 ms 2820 KB Execution killed with signal 6
54 Runtime error 34 ms 4052 KB Execution killed with signal 6
55 Runtime error 24 ms 2768 KB Execution killed with signal 6
56 Runtime error 26 ms 3480 KB Execution killed with signal 6
57 Correct 42 ms 3020 KB Output is correct
58 Runtime error 39 ms 4948 KB Execution killed with signal 6
59 Runtime error 31 ms 4044 KB Execution killed with signal 6
60 Runtime error 43 ms 5176 KB Execution killed with signal 6
61 Correct 40 ms 3112 KB Output is correct
62 Runtime error 40 ms 5332 KB Execution killed with signal 6
63 Runtime error 33 ms 6340 KB Execution killed with signal 6
64 Runtime error 44 ms 5432 KB Execution killed with signal 6
65 Correct 50 ms 3148 KB Output is correct
66 Runtime error 25 ms 3460 KB Execution killed with signal 6
67 Correct 38 ms 3200 KB Output is correct
68 Runtime error 37 ms 6348 KB Execution killed with signal 6
69 Correct 22 ms 3148 KB Output is correct
70 Runtime error 48 ms 6304 KB Execution killed with signal 6
71 Runtime error 36 ms 4732 KB Execution killed with signal 6
72 Runtime error 39 ms 6332 KB Execution killed with signal 6
73 Runtime error 42 ms 6348 KB Execution killed with signal 6
74 Incorrect 47 ms 3060 KB Output isn't correct
75 Runtime error 32 ms 4348 KB Execution killed with signal 6
76 Runtime error 49 ms 6336 KB Execution killed with signal 6
77 Correct 37 ms 3216 KB Output is correct
78 Runtime error 39 ms 5148 KB Execution killed with signal 6
79 Incorrect 37 ms 3144 KB Output isn't correct
80 Runtime error 32 ms 6280 KB Execution killed with signal 6
81 Runtime error 41 ms 6300 KB Execution killed with signal 6
82 Runtime error 37 ms 4908 KB Execution killed with signal 6
83 Runtime error 47 ms 6324 KB Execution killed with signal 6
84 Runtime error 38 ms 4832 KB Execution killed with signal 6
85 Runtime error 42 ms 6520 KB Execution killed with signal 6
86 Correct 43 ms 2880 KB Output is correct
87 Runtime error 38 ms 5000 KB Execution killed with signal 6
88 Runtime error 50 ms 6400 KB Execution killed with signal 6
89 Runtime error 31 ms 6296 KB Execution killed with signal 6
90 Correct 41 ms 3212 KB Output is correct
91 Runtime error 52 ms 6316 KB Execution killed with signal 6
92 Runtime error 40 ms 6388 KB Execution killed with signal 6
93 Runtime error 53 ms 6304 KB Execution killed with signal 6
94 Runtime error 30 ms 3516 KB Execution killed with signal 6
95 Correct 42 ms 3224 KB Output is correct
96 Runtime error 37 ms 4828 KB Execution killed with signal 6
97 Runtime error 44 ms 6352 KB Execution killed with signal 6
98 Correct 36 ms 2572 KB Output is correct
99 Runtime error 26 ms 3444 KB Execution killed with signal 6
100 Runtime error 43 ms 5568 KB Execution killed with signal 6
101 Runtime error 43 ms 6348 KB Execution killed with signal 6
102 Correct 29 ms 3212 KB Output is correct