# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
151873 | tmwilliamlin168 | FunctionCup Museum (FXCUP4_museum) | C++17 | 185 ms | 14144 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 "museum.h"
#include <bits/stdc++.h>
using namespace std;
long long CountSimilarPairs(vector<int> b, vector<int> t, vector<int> g) {
long long ans=0;
for(int i=1; i<8; ++i) {
unordered_map<int, int> mp;
for(int j=0; j<b.size(); ++j) {
int k=((i&1?b[j]:0)*101+(i&2?t[j]:0))*101+(i&4?g[j]:0);
ans+=(mp[k]++)*(__builtin_popcount(i)%2*2-1);
}
}
return ans;
}
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |