Submission #121668

#TimeUsernameProblemLanguageResultExecution timeMemory
121668ly20Art Class (IOI13_artclass)C++17
2 / 100
100 ms5880 KiB
#include<bits/stdc++.h> using namespace std; #include"artclass.h" int style(int H,int W,int R[500][500],int G[500][500],int B[500][500]) { int r=0,g=0,b=0; for(int i=0;i<500;i++) for(int j=0;j<500;j++) { r+=R[i][j]; g+=G[i][j]; b+=B[i][j]; } int mg=500*500*50; int resp; if(g-mg>r && g-mg>b)resp=2; else if(r-mg>b && g-mg>b)resp=4; else if(r>=125 && g>=125 && b>=125)resp=3; else resp=1; return resp; }
#Verdict Execution timeMemoryGrader output
Fetching results...