# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
234931 | muhammad_hokimiyon | Art Class (IOI13_artclass) | C++14 | 78 ms | 3328 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 H, int W, int R[500][500], int G[500][500], int B[500][500])
{
int a = 0 , b = 0 , c = 0;
int t = 0;
for( int i = 0; i < H; i++ ){
for( int j = 0; j < W; j++ ){
if( R[i][j] > max(G[i][j] , B[i][j]) )a += 1;
else if( G[i][j] > max(R[i][j] , B[i][j]) )b += 1;
else if( B[i][j] > max(R[i][j] , G[i][j]) )c += 1;
if( R[i][j] + G[i][j] + B[i][j] > 700 )t += 1;
}
}
if( a >= max(b , c) )return 2;
if( t * 1.0 >= 1.0 * H * W * 30 / 100 )return 1;
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
if( rng() % 2 )return 3;
return 4;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |