12 2022 档案
摘要:快速排序主要是分治的思想,找到枢轴元素,并递归的找两边的枢轴元素,直至有序 #include<stdio.h> void QuickSort(int A[],int low,int high){ int l=low,h=high; if(low<high){ int pivot=A[low];//将
阅读全文
摘要:#include<stdio.h> #include <math.h> typedef int ElemType; void SelectSort(ElemType A[],int n){ int t,min,i=0,j=0,flag; for( i=0;i<=n-1;i++){ min=i; fl
阅读全文

浙公网安备 33010602011771号