Submission #502

#TimeUsernameProblemLanguageResultExecution timeMemory
502pl0892029짝수 정렬 (tutorial3)C++98
100 / 100
0 ms912 KiB
#include <grader.h> void sort_even(int N,int *A) { int S[100]; int i,j,n=0; for(i=0;i<N;i++) if(A[i]%2==0) S[n++]=A[i]; for(i=n-1;i>0;i--) for(j=0;j<i;j++) if(S[j]>S[j+1]) { S[j+1]+=S[j]; S[j]=S[j+1]-S[j]; S[j+1]-=S[j]; } for(i=0;i<n;i++) Report(S[i]); }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...