Submission #249232

# Submission time Handle Problem Language Result Execution time Memory
249232 2020-07-14T13:56:21 Z sahil_k Fireworks (APIO16_fireworks) C++14
0 / 100
1 ms 384 KB
#include <iostream>
#include <map>
using namespace std;
int n, m;
map<int, int> freq;
int main () {
	cin >> n >> m;
	int ai;
	for (int i=0; i<m; i++) {
		cin >> ai;
		freq[ai]++;
	}
	int o = m;
	for (auto i: freq) {
		o = min(o, m-i.second);
	}
	cout << o << endl;
}
# Verdict Execution time Memory Grader output
1 Correct 1 ms 384 KB Output is correct
2 Incorrect 0 ms 256 KB Output isn't correct
3 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 256 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 384 KB Output is correct
2 Incorrect 0 ms 256 KB Output isn't correct
3 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 384 KB Output is correct
2 Incorrect 0 ms 256 KB Output isn't correct
3 Halted 0 ms 0 KB -