# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
474734 | ValiAntonie | Art Class (IOI13_artclass) | C++14 | 79 ms | 3268 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include "artclass.h"
#include <bits/stdc++.h>
using namespace std;
int style(int n, int m, int R[500][500], int G[500][500], int B[500][500]) {
int i = 0, j = 0, nrverde = 0, nralb = 0, nrnegru = 0;
for(i=0;i<n;i++){
for(j=0;j<m;j++){
if(G[i][j] > R[i][j] && G[i][j] > B[i][j])
nrverde++;
if(G[i][j] >= 200 && R[i][j] >= 200 && B[i][j] >= 200)
nralb++;
if(G[i][j] <=50 && R[i][j] <= 50 && B[i][j] <= 50)
nrnegru++;
}
}
if(nrverde > (2 * n * m) / 3)
return 2;
else if(nralb > (2 * n * m) / 3)
return 3;
else if(nrnegru > (n * m) / 6)
return 1;
else
return 4;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |