Submission #415209

#TimeUsernameProblemLanguageResultExecution timeMemory
415209ly20Aliens (IOI16_aliens)C++17
4 / 100
2 ms332 KiB
#include "aliens.h" #include <bits/stdc++.h> using namespace std; const int MAXN = 110; int tb[MAXN][MAXN]; long long take_photos(int n, int m, int k, vector<int> r, vector<int> c) { if(n != k) return 0; for(int i = 0; i < n; i++) { int a = min(r[i], c[i]), b = max(r[i], c[i]); for(int j = a; j <= b; j++) { for(int k = a; k <= b; k++) { tb[j][k] = 1; } } } long long resp = 0; for(int i = 0; i < MAXN; i++) { for(int j = 0; j < MAXN; j++) resp += tb[i][j]; } return resp; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...