1067 Sort with Swap(0, i) (25 分)
注:贪心
#include#include using namespace std; const int maxn=100100; int pos[maxn]; int main () { int n,i,a,q=0,left=0; scanf ("%d",&n); for (i=0;i 0) { if (pos[0]==0) { while (k

1067 Sort with Swap(0, i) (25 分)
注:贪心
#include#include using namespace std; const int maxn=100100; int pos[maxn]; int main () { int n,i,a,q=0,left=0; scanf ("%d",&n); for (i=0;i 0) { if (pos[0]==0) { while (k