Submission #992591

# Submission time Handle Problem Language Result Execution time Memory
992591 2024-06-04T18:15:17 Z KasymK Magic Show (APIO24_show) C++17
5 / 100
3 ms 1088 KB
#include "bits/stdc++.h"
#include "Alice.h"
using namespace std;
 
vector<pair<int, int>> Alice(){
  long long x = setN(5000);
  vector<pair<int, int>> v;
  for(int i = 1; i <= 5000; ++i)
    	if(i != x)
          	v.push_back({i, x});
  return v;
}
#include "bits/stdc++.h"
#include "Bob.h"
using namespace std;
 
long long Bob(vector<pair<int, int>> v){
  map<int, int> mp;
  for(auto &i : v)
    	mp[i.second]++;
  int mx = -1, answer = -1;
  for(auto &i : v)
    	mx = max(mx, mp[i.second]);
  for(auto &i : v)
    	if(mx == mp[i.second]){
          answer = i.second;
          break;
        }
  return answer;
}
# Verdict Execution time Memory Grader output
1 Correct 2 ms 828 KB Correct.
2 Correct 1 ms 820 KB Correct.
3 Correct 1 ms 820 KB Correct.
4 Correct 2 ms 820 KB Correct.
5 Correct 2 ms 1080 KB Correct.
6 Correct 3 ms 820 KB Correct.
7 Correct 2 ms 1088 KB Correct.
8 Correct 2 ms 820 KB Correct.
9 Correct 2 ms 1076 KB Correct.
10 Correct 2 ms 820 KB Correct.
11 Correct 2 ms 1088 KB Correct.
12 Correct 2 ms 1076 KB Correct.
# Verdict Execution time Memory Grader output
1 Correct 2 ms 828 KB Correct.
2 Correct 1 ms 820 KB Correct.
3 Correct 1 ms 820 KB Correct.
4 Correct 2 ms 820 KB Correct.
5 Correct 2 ms 1080 KB Correct.
6 Correct 3 ms 820 KB Correct.
7 Correct 2 ms 1088 KB Correct.
8 Correct 2 ms 820 KB Correct.
9 Correct 2 ms 1076 KB Correct.
10 Correct 2 ms 820 KB Correct.
11 Correct 2 ms 1088 KB Correct.
12 Correct 2 ms 1076 KB Correct.
13 Incorrect 0 ms 344 KB Output isn't correct
14 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 2 ms 828 KB Correct.
2 Correct 1 ms 820 KB Correct.
3 Correct 1 ms 820 KB Correct.
4 Correct 2 ms 820 KB Correct.
5 Correct 2 ms 1080 KB Correct.
6 Correct 3 ms 820 KB Correct.
7 Correct 2 ms 1088 KB Correct.
8 Correct 2 ms 820 KB Correct.
9 Correct 2 ms 1076 KB Correct.
10 Correct 2 ms 820 KB Correct.
11 Correct 2 ms 1088 KB Correct.
12 Correct 2 ms 1076 KB Correct.
13 Incorrect 0 ms 344 KB Output isn't correct
14 Halted 0 ms 0 KB -