# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
516217 |
2022-01-20T16:21:50 Z |
Mounir |
Party (POI11_imp) |
C++14 |
|
1305 ms |
292 KB |
#include <bits/stdc++.h>
#define all(v) v.begin(), v.end()
#define sz(x) (int)x.size()
#define pb push_back
#define pii pair<int, int>
#define chmin(x, v) x = min(x, v)
#define chmax(x, v) x = max(x, v)
#define x first
#define y second
#define int long long
using namespace std;
signed main(){
int nNoeuds, nAretes; cin >> nNoeuds >> nAretes;
vector<int> degres(nNoeuds);
for (int iArete = 0; iArete < nAretes; ++iArete){
int noeud, voisin; cin >> noeud >> voisin;
degres[noeud - 1]++;
degres[voisin - 1]++;
}
int reste = nNoeuds/3;
for (int noeud = 0; noeud < nNoeuds; ++noeud){
if (degres[noeud] >= ceil(nNoeuds/double(2)) && reste > 0){
cout << noeud + 1 << " ";
reste--;
}
}
cout << endl;
return 0;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
1 ms |
204 KB |
Nie wszystkie wypisane osoby siê znaja |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
5 ms |
204 KB |
Nie wszystkie wypisane osoby siê znaja |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
19 ms |
204 KB |
Nie wszystkie wypisane osoby siê znaja |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
45 ms |
204 KB |
Nie wszystkie wypisane osoby siê znaja |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
107 ms |
276 KB |
Nie wszystkie wypisane osoby siê znaja |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
312 ms |
204 KB |
Nie wszystkie wypisane osoby siê znaja |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
570 ms |
284 KB |
Nie wszystkie wypisane osoby siê znaja |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
760 ms |
284 KB |
Nie wszystkie wypisane osoby siê znaja |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
920 ms |
292 KB |
Nie wszystkie wypisane osoby siê znaja |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
1093 ms |
288 KB |
Nie wszystkie wypisane osoby siê znaja |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
1305 ms |
288 KB |
Nie wszystkie wypisane osoby siê znaja |
2 |
Halted |
0 ms |
0 KB |
- |