Submission #14161

# Submission time Handle Problem Language Result Execution time Memory
14161 2015-05-02T19:28:08 Z pichulia 버블 정렬 (OJUZ10_bubblesort) C++
0 / 100
55 ms 2644 KB
#include<stdio.h>
#include<algorithm>
using namespace std;
typedef pair<int, int> pii;
int n, m;
int a[100009];
pii b[100009];
int c[100009];
int main()
{
	int i, j, k, l;
	scanf("%d %d",&n,&m);
	for(i=0;i<n;i++){scanf("%d",&a[i]);b[i].first=a[i];b[i].second = i;}
	sort(b,b+n);
	for(i=0;i<m;i++)
		c[b[n-i-1].second]=1;
	for(i=0;i<n;i++)
		if(c[i]==0)
		printf("%d ",a[i]);
	for(i=0;i<m;i++)
		printf("%d ",b[i+n-m].first);
}
# Verdict Execution time Memory Grader output
1 Correct 0 ms 2644 KB Output is correct
2 Incorrect 0 ms 2644 KB Output isn't correct
3 Incorrect 0 ms 2644 KB Output isn't correct
4 Incorrect 0 ms 2644 KB Output isn't correct
5 Incorrect 0 ms 2644 KB Output isn't correct
6 Incorrect 0 ms 2644 KB Output isn't correct
7 Incorrect 0 ms 2644 KB Output isn't correct
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 2644 KB Output isn't correct
2 Incorrect 1 ms 2644 KB Output isn't correct
3 Incorrect 1 ms 2644 KB Output isn't correct
4 Incorrect 0 ms 2644 KB Output isn't correct
5 Incorrect 0 ms 2644 KB Output isn't correct
6 Incorrect 0 ms 2644 KB Output isn't correct
7 Incorrect 0 ms 2644 KB Output isn't correct
8 Correct 0 ms 2644 KB Output is correct
9 Incorrect 0 ms 2644 KB Output isn't correct
10 Incorrect 0 ms 2644 KB Output isn't correct
# Verdict Execution time Memory Grader output
1 Incorrect 37 ms 2644 KB Output isn't correct
2 Incorrect 36 ms 2644 KB Output isn't correct
3 Incorrect 41 ms 2644 KB Output isn't correct
4 Incorrect 39 ms 2644 KB Output isn't correct
5 Incorrect 28 ms 2644 KB Output isn't correct
6 Incorrect 45 ms 2644 KB Output isn't correct
7 Incorrect 19 ms 2644 KB Output isn't correct
8 Incorrect 33 ms 2644 KB Output isn't correct
9 Incorrect 36 ms 2644 KB Output isn't correct
10 Incorrect 25 ms 2644 KB Output isn't correct
11 Correct 35 ms 2644 KB Output is correct
12 Incorrect 34 ms 2644 KB Output isn't correct
13 Incorrect 43 ms 2644 KB Output isn't correct
14 Incorrect 55 ms 2644 KB Output isn't correct
15 Incorrect 54 ms 2644 KB Output isn't correct
# Verdict Execution time Memory Grader output
1 Incorrect 25 ms 2644 KB Output isn't correct
2 Incorrect 20 ms 2644 KB Output isn't correct
3 Incorrect 38 ms 2644 KB Output isn't correct
4 Incorrect 34 ms 2644 KB Output isn't correct
5 Incorrect 35 ms 2644 KB Output isn't correct
6 Incorrect 38 ms 2644 KB Output isn't correct
7 Incorrect 36 ms 2644 KB Output isn't correct
8 Correct 52 ms 2644 KB Output is correct
9 Incorrect 42 ms 2644 KB Output isn't correct
10 Incorrect 42 ms 2644 KB Output isn't correct
11 Incorrect 55 ms 2644 KB Output isn't correct
12 Incorrect 44 ms 2644 KB Output isn't correct
13 Incorrect 31 ms 2644 KB Output isn't correct
14 Incorrect 34 ms 2644 KB Output isn't correct
15 Incorrect 41 ms 2644 KB Output isn't correct