Submission #783259

#TimeUsernameProblemLanguageResultExecution timeMemory
783259vh50L-triominoes (CEOI21_ltriominoes)C++17
7 / 100
1 ms300 KiB
#include <bits/stdc++.h> #define int long long #define endl "\n" using namespace std; int n, m, k; main() { cin >> n >> m >> k; for(int i = 0; i < k; i++) { int a, b; cin >> a >> b; } if((n * m - k) % 6 == 0) cout << "YES" << endl; else if(n == 3 || m == 3) cout << "NO" << endl; else if(n % 3 == 0 || m % 3 == 0) cout << "YES" << endl; else cout << "NO" << endl; }

Compilation message (stderr)

ltrominoes.cpp:6:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    6 | main()
      | ^~~~
#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...