文件名称:heapsort
介绍说明--下载内容均来自于网络,请自行研究使用
从最后一个非叶子结点开始从后往前进行调整,保证了根下的所有子树都是最大堆,最后对根进行调整,使整棵二叉树为最大堆,保证了根结点为整棵数的最大值点,完成了建堆的过程,再将根结点跟最后一个结点进行交换,如此反复操作,则堆排序就完成了,其中堆排序的过程采用了满二叉树的概念。-From the final of a non-leaf node after the move began to be adjusted to ensure that the root of all sub-tree are the biggest pile, and finally adjusted to the root, so that the largest heap binary tree整棵to ensure that the root node for整棵the maximum number of points, completed the process of building reactors, and then the last root node with a node to be exchanged, and so repeated the operation, then HEAPSORT completed, of which the process of HEAPSORT a full binary tree concept.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
heapsort
........\heapsort.cpp
........\heapsort.cpp